Jump to content
BadAss -Mapfact.net-

Mapfact.net releases DAC

Recommended Posts

Thanks for the help, but it does not work. I have tried different approaches to the problem but none seems to work.

Shall I send you the mission so that you can have a look at the problem?

Share this post


Link to post
Share on other sites

hi,

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Shall I send you the mission so that you can have a look at the problem?

yes...please.

Share this post


Link to post
Share on other sites

hi,

@Zendjir

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">-But then, when some groups are killed, they respawn, and that's when the sh** hits the fan. When monitoring the behaviour of the groups on the map it seems they don't really know what they are supposed to do. Sometimes they move in directions where no waypoint is present. Sometimes they pause for no apparent reason. Sometimes they just move around aimlessly in the zone where they have been created. And occasionaly they do seem to care about their objectives and move towards a waypoint.

Unfortunately I cannot reconstruct this failure correctly yet confused_o.gif

I can only say that there are no problems with the following attitudes with me (and your mission).

Everything functions in such a way, as it should function. Also after several Respawns...

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

DAC_KI_Level = 4

DAC_KI_AddOn = 1

In addition I deactivated your Scripts first times.

I have however still a few important notes for you, which you should consider:

# Avoid the game acceleration. It is not completely safe whether that causes errors.

# Generate always somewhat more waypoints like being needed. If a group is to get for example 10 waypoints, then should be available 12 to 15 waypoints for the selection.

In the following a picture, which explains still further characteristics....

dacxcam4cj9.jpg

1) Fights will not always take place at the desired positions.

They can shift outside of the zones. That comes by the dynamics of DAC (and by the existing dynamics of OFP) smile_o.gif

2) You should make certain that zones of east and west are not to close together.

It can happen otherwise that the Camps is generated nearly next to each other.

That would contribute then also again to inadvertent fights.

3) In each master zone at least one waypoint is generated, so that the units can be produced at the beginning there.

By the fact it can happen that a group moves again back, in order to reach the waypoint in the master zone.

4 + 5) Units move not in principle on the shortest way to their waypoint.

Often they use a small detour and move thereby in an elbow towards their waypoint.

That comes not from DAC, but is a normal behavior of the OFP AI.

6) Because the zones in the north and in the west are linked can it pass that the units move from the one to the other master zone. And again not on the direct way.

Here still another picture of another zone placement,

like it functions also perfectly and also without any Failure.

In this example can be generated some more units, since the distances are somewhat larger.

dacxcam5ye3.jpg

But I will accomplish still another further test. smile_o.gif

bye

silola

Share this post


Link to post
Share on other sites

Thanks for the help Silola, thanks to you I was able to track down the problem. Especially the hint not to use game acceleration. I was able to track down the problem to my AI script. The fact that I was seeing the problem while not using the scripts was due to the fact that I used game acceleration to speed up the testing progress. Thanks a bunch for your help, you really made my day smile_o.gif

Share this post


Link to post
Share on other sites

I have released my Extended AI version 2 in the mission editing & scripting forum. Since the scripts are DAC compatible I will also release them here. Please post your comments and questions in the thread in the mission editing & scripting forum.

Extended AI v2 thread

Readme:

Extended AI script V.2

By Zendjir

I am proud to present to you the second version of my AI script. The first version was published in the DAC thread a while ago. The script significantly improves the AI of individual AI groups and is fully DAC and MP compatible and its lag-free! It can also be used in non-DAC missions. Read the instructions below. With this script running the AI will:

· Be more cautious.

· It will make better use of cover when under fire.

· It will enter buildings when possible.

· It will face the direction of the nearest known enemy

· It will not send its men on suicide missions.

· It will be more cautious when operating an armed groundvehicle.

· It will say random things.

Contents of download file:

-Readme

-3 examplemissions with the script implemented, one for each type of mission that are described in the installation instructions. They are purely intended for example purposes and should be played as such, they are not full blown missions. The non-dac mission will end after you have killed all enemies in the area, the other 2 missions will never end.

- Environment.sqs script included as an extra;

As OFP lacks environmental sounds IMO. I have taken some sounds from the internet and created this script. It will create the sounds by continiously moving gamelogics around the players position and letting these gamelogics say a specific sound

For more details see the script + the mission.

The sounds you can choose from as of yet are defined in the description.txt

Note: this script has NOT been tested for MP, it would be best to remove the gamelogics that call the script if you are planning to make an MP mission.

Installation instructions.

Non-DAC mission.

Place the following in your mission folder:

- the Extai folder

- the description.txt (or modify an already existing one to include the soundfiles)

- the init.sqs (or modify an already existing one)

To set up the script: make 2 triggers covering all the units in the mission; one to detect all east units in the area and one to detect all west units. In the activation field type DAC_east_units= thislist and DAC_west_units= thislist respectively and type Runaiscripts==1 in the condition field.

For each group that you want to run the script (including vehicle groups), type [group this] exec "Extai\adveast.sqs" or [group this] exec "Extai\advwest.sqs" in one(!wink_o.gif of the group's soldiers init line, depending on the side of the group. Finally, place a logic named ‘server’ in the mission if you want to play the mission in multiplayer.

Next edit the following lines in the init.sqs:

Set: Runaiscripts=1

RunSTspeak=true (if you want to have the soldiers of a group say random stuff, otherwise set it to false)

RunCombatspeak=true (if you want to have the soldiers of a group say combat oriented things when they encounter an enemy, otherwise set it to false)

You can also check the demo-missions to see how this is done.

That’s it, you can now run the mission.

DAC-mission.

Place the following in your mission folder:

- the Extai folder

- the description.txt (or modify an already existing one to include the soundfiles)

- the init.sqs (or modify an already existing one)

Make sure that DAC_Cache_units in the DAC scripts folder is replaced by the one provided in the demomission. Also replace DAC_Reduce_group with the one provided in the demomission. This last replacement has nothing to do with the scripts but includes a fix provided by Silola (DAC creator) so that AT soldiers keep their ammo after their group has been reduced by DAC. Finally, place a logic named ‘server’ in the mission.

Next: make 2 triggers covering all the units in the mission; one to detect all east units in the area and one to detect all west units. In the activation field type: ‘DAC_East_units= DAC_East_units + (thislist - DAC_East_units)’ and DAC_west_units= DAC_West_units + (thislist – DAC_West_units) thislist respectively and type Runaiscripts==1 in the condition field.

Next edit the following lines in the init.sqs:

Set: Runaiscripts=0

RunSTspeak=true (if you want to have the soldiers of a group say random stuff, otherwise set it to false)

RunCombatspeak=true (if you want to have the soldiers of a group say combat oriented things when they encounter an enemy, otherwise set it to false)

You can also check the demo-missions to see how this is done.

That’s it, you can now run the mission.

DAC-mission with editor placed AI groups.

First, follow the installation instructions for the DAC-mission described above.

You can then run the script on each editor placed group you like (including vehicle groups) by typing [group this] exec "Extai\adveast.sqs" or [group this] exec "Extai\advwest.sqs" in one(!wink_o.gif of the group's soldiers init line, depending on the side of the group.

You can also check the demo-missions to see how this is done.

That’s it, you can now run the mission.

Known issues:

- Combat will be less fast-paced, this was intended but may not be to everyones liking.

- The script may interfere with behavioural changes determined outside of the scripts, I have taken precautions against this occurence but it may still happen.

- The soldiers will exit vehicles when they are riding in cargo and enemies are detected. After the enemies are dead they will not re-enter the vehicle on their own. A GET IN waypoint is required for that.

- The AI will behave erratically when the player takes over command over the group, don’t let the player command a group that runs the script.

- The custom voicefiles do not have lip-files, I could not get wavtolip to work.

- Sometimes a zero-devisor error appears when DAC reduces groups. This issue is being worked on but does not interfere with the functioning of DAC or the ai-scripts. It is just an irritating distraction.

Thanks:

Silola; for creating DAC and for adequatly answering all questions I had surrounding it.

Sickboy; for making the scripts multiplayer compatible, for providing a cleaner script structure and for testing the scripts.

Disclaimer:

The user of these scripts should be aware that the script is not related to BIS or Codemasters in any way, it is an unofficial addition to your flashpoint experience. The scripts may not be used for commercial purposes. The rights of the individual soundfiles belong to their respective owners. Feel free to use or modify these scripts in a non-commercial way, just list me as the author of it if you are using it or have used significant parts of the scripts in your own scripts. Sickboy is the author of the scripts that list him as the author, and he should be treated as such.

Linky:

Download extended AI v2

Share this post


Link to post
Share on other sites

Zendjir, it works quite well.

What do the game logics with all the waypoints do?

ARe they also part of the environmental sounds? I was curious to see if I could remove them?

Share this post


Link to post
Share on other sites

No, they are a DAC method of manually placing waypoints. I have placed them since I wanted a townbattle in the demomissions.

You should not remove them.

Share this post


Link to post
Share on other sites

just a question but has any one tested if DAC and farmland zombies or so could be used togheter? Would be cool to spawn 'em zombies and it would probably help keep lag down alot maybe.

Share this post


Link to post
Share on other sites

Im making a MP compatiable mission that uses DAC. Its basically a CTI with DAC and CoC CE. My problem is on MP the large amount of troops generated lag the crap out of the server computer. The clients are just fine, and have all the fun. I was wondering is there some sort of way to reduce the lag but keep the density of enemy generated troops on the island. I have reduced the amount of groups, but the result lessened the intensity of the overall mission. Ill probably just have to use a smaller island. But i figured I asked. And oh by the way, I am using camps and respawn.

Another question, I want to make more buildings appear with the camps just for eye candy. I tried editing the Dac_group_camp or whatever the script was called, but never got it to pump out the extra building.

And one more question. Sometimes ill get a DAC error saying that process interupted because a camp is not suitable. Why is this?

Share this post


Link to post
Share on other sites

Silola, a new question from me smile_o.gif

I seem to have found a somewhat weird result, which I am going to test tonight with 8 players, to see what is causing it...

But as following:

I have a DAC mission...

When I play it with 23 AI players, and myself, that makes 24 total...

After the dac init etc... the dedicated server fps is about 35-45fps, which is very good (since 50 is the max of a deddy server)...

Now the problem is, if I play the same mission, but now with 12 players, and no AI (so there is even HALF of the amount of DAC_Players), and I check the server fps around the same moment etc. it's only 13-15fps (also after continued retry, the same results come in)

I remember this being slightly better before, but still.. with many players I always had a low server fps...

I am now wondering, if you know anything within DAC, that could cause such heavy server fps drop...

I find it very weird, since DAC_Players is filled with AI and/or real players, and I would not know a reason why it would cause so much fps drop when real players are in, compared to AI players.

(Except that AI players run locally on the server, while Players run locally on their client, still...)

This seems not to be such a big problem when playing non-dac missions, but it has been a while since I throughly tested non-dac missions I must add!

Tonight i'm going to disable all my eventhandlers and other scripts that are running, to figure out if it has anything to do with DAC or simply some scripts that are running or whatsoever..

I am using the edited version of DAC with the extra value in dac_ki_spawn to check distance between DAC_Players and spawn camps for either the destroying of the camp or the spawning of the enemies... I will also try the original version tonight

But I thought I would first drop you the question, if you might know why dac would generate so much server lag when there are players instead of AI running around..

Thanks for any help/insights!!

And one more question. Sometimes ill get a DAC error saying that process interupted because a camp is not suitable. Why is this?

That means that in the area where you want to create spawncamps, there is not enough usable terrain to place it, as configured in your waypoints.sqs. Check the readme for more info on that.. as quickfix, make bigger zones..

Share this post


Link to post
Share on other sites

Hello there wink_o.gif

Silola, little qestion: is it possible to make a respawn for ai without building a camp? and how can i do, so the ai respawns faster? confused_o.gif

Share this post


Link to post
Share on other sites

hi,

@Combat-Agent

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Im making a MP compatiable mission that uses DAC. Its basically a CTI with DAC and CoC CE.

My problem is on MP the large amount of troops generated lag the crap out of the server computer.

The clients are just fine, and have all the fun.

I was wondering is there some sort of way to reduce the lag but keep the density of enemy generated

troops on the island. I have reduced the amount of groups, but the result lessened the intensity

of the overall mission. Ill probably just have to use a smaller island. But i figured I asked.

And oh by the way, I am using camps and respawn.

That the server is overloaded, must not be an DAC problem. It can have many reasons.

DAC is besides not able to make from a not playable mission suddenly a playable mission.

DAC has to fight with the same problems, like other mission.

For example on a very extensive island, if many groups are generated,

which besides of hight Polycount units consist, also DAC thereby will have problems.

Here a few tips, which you should consider:

- Does the mission run on a “dedicated server�

- Deactivate the DAC_Markers. These are not supported in MP games.

The marker scripts do not have to be unnecessarily activated.

- Examine whether the logic “server†is present.

- Is the group reduction activated ? And are the attitudes optimally selected ?

- Is the deletion of units activated? Is the attitude optimal?

- If you deactivate the group reduction, do you notice then that it runs still more badly?

- Examine the number of groups, which are generated on each sides. How many is there?

- Reduce something the number of groups, which are generated.

- Reduce the number of units, which are generated for each group.

- Generate rather somewhat more infantry than vehicles. Then can be reduced also more groups.

- Test the mission on an standard island, with standard units. How does the mission behave then?

- Are further scripts on group level active, or even on unit level, which runs on the server?

If possible, deactivate these scripts for one test, to examine whether the performance is affected by it.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">And one more question. Sometimes ill get a DAC error saying that process interupted because a camp is not suitable. Why is this?

This error meant that in a zone, in which one or more Camps are to be generated,

it gives no suitable positions there.

There are several possibilities of minimizing an arising of the error:

- Increase the size of the zone, so that there are more possibilities for the placement of Camps .

- Tries to find a better position for the zone.

- Change the values for Camps in the DAC_Config_Waipoints.sqs

;\\\\\\\\\\\\\\\\\\\\\\\\\\\

#WP_Typ_5

;-----------> | Camp |

;///////////////////////////

_CheckRadius = 40

_checkAreaH = 20

_checkMaxH = 1000

_checkMinH = 5

_checkNear = 100

_checkObjH = 4

_checkCount = 500

_TempWPArray = DAC_WP_Pool_C

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">Another question, I want to make more buildings appear with the camps just for eye candy.

I tried editing the Dac_group_camp or whatever the script was called, but never got it to pump

out the extra building.

Wait for DAC version V1.2 wink_o.gif

I answer the other questions later...

bye

silola

Share this post


Link to post
Share on other sites

hi again smile_o.gif

@mcbean:

In principle at least one Camp is needed, in order to activate the Respawn.

It is however possible to set all Camp objects on a not relevant position.

It must stay only one object, so that at this position units can be generated.

This object must be then only an invisible helipad.

With this action you reach that the units are generated not in a Camp,

but only at a position, which determined DAC randomly.

And so you can make it:

First you change the "DAC\DAC_Config_Units.sqs" :

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">_Unit_Pool_C = ["usa_vlajka.pac","HeliHempty","HeliHempty",[100,3]]

Then still another small change in the Script “DAC \ KI_1 \ DAC_Move_Camps.sqs†:

Below this line "@((getdir DAC_StartDummy) > 170)"

you insert this new line:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">@((getdir DAC_StartDummy) > 170)

{if(!(_x == _buildingA)) then {_x setpos [0,0];if(format["%1",typeof _x] == "fire") then {_x inflame false}}}foreach _camparray

Unfortunately the Respawn cannot be shortened, since OFP needs a certain time,

until actually no more units are in the group present.

DAC needs this waiting period, so that the new units in correct order are generated

and also, so that enough place is present in the group.

bye

silola

Share this post


Link to post
Share on other sites

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">@((getdir DAC_StartDummy) > 170)

{if(!(_x == _buildingA)) then {_x setpos [0,0];if(format["%1",typeof _x] == "fire") then {_x inflame false}}}foreach _camparray

Is there any reason why the fire could not also be setPos to [0,0]?

Share this post


Link to post
Share on other sites

hi,

The fire is set also to this position. Only the respawn building not wink_o.gif

bye

silola

Share this post


Link to post
Share on other sites

theres been so many things added and removed from dac i dont no whats been updated. will someone be able to send me an updated version with goodies in? pleaasse biggrin_o.gif

Share this post


Link to post
Share on other sites

hi,

my version I cannot give you unfortunately tounge2.gif

The contained changes and innovations, you can not note without a reasonable Readme.

It is by the way now also possible, while the mission runs, to reload at any time a new "Config_Unit" and a new "Config_Behaviour" for each zone smile_o.gif

Camps can be assigned now completely simply to individual zones. Thus the Respawn can be divided and proportioned optimally.

Camps have now their own “Conigâ€, whereby now substantially more possibilities are ordered....and so on.

And… the moveable zones are also cool. Either the units move normally to their new zone, or alternatively, those units directly there are positioned, in order to take up their new waypoints then wink_o.gif

bye

silola

Share this post


Link to post
Share on other sites

any1 tried adding east zones and then trhwoing in west zones on top or close by too see what happens? smile_o.gif

Share this post


Link to post
Share on other sites

I tried. Gunfight? (that's the reason I really like it)

Share this post


Link to post
Share on other sites
any1 tried adding east zones and then trhwoing in west zones on top or close by too see what happens?  smile_o.gif

i also.. was fun smile_o.gif

Share this post


Link to post
Share on other sites

Is there a way to make waypoint only zones for helicopters? I tried the regular way (like for inf/vehicles/armor) but I think it didn't work. If it isn't possible, I'd suggest that you (Silola) implement it in the next release whistle.gif . By my understanding, it wouldn't be a problem.

Share this post


Link to post
Share on other sites

hi smile_o.gif

That should normally work without problems. You need always a master zone. That are the zone, where the heli is generated and is stationed.

You can connect then as many as desired waypoint zones with the master zone. Here an example with 1MZ+3WZ zones:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

[hz1,[1,0,0],[],[],[],[1,2,4],[0,0,0]]exec "DAC\Scripts\DAC_Init_Zone.sqs"

[hz2,[1,0,0],[],[],[],[4],[0,0,0]]exec "DAC\Scripts\DAC_Init_Zone.sqs"

[hz3,[1,0,0],[],[],[],[3],[0,0,0]]exec "DAC\Scripts\DAC_Init_Zone.sqs"

[hz4,[1,0,0],[],[],[],[4],[0,0,0]]exec "DAC\Scripts\DAC_Init_Zone.sqs"

DAC sends the heli randomly into one of the four zones. If the heli flies e.g. to the zone “z3â€, then he will approach there 3 random waypoints.

If the heli flies to the zone “hz2â€, then he has to settle 4 waypoints there smile_o.gif

bye

silola

Share this post


Link to post
Share on other sites

Thanks for your help!

Probably I set up something wrong then. I thought it works just like you said. I'll try it again, when time allows.

Bye

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×