Jump to content

Recommended Posts

I've been trying to get AI to use vehicles detected using the methods described. My current setup is the following.

A anybody present trigger with several APCs within it, with the following activation:

vehlist = (thisList select {(vehicle _x) isKindOf "LandVehicle"});

I then have gamelogic with manually-defined list of groups:

b_grouplist = [squad1,squad2]

I then have another gamelogic with the following:

{
_vehiclechoice = selectRandom vehlist;
_x addVehicle _vehiclechoice;
}
forEach b_grouplist;
hint "vehicles added";

(I initially tried adding that code via an sqf file, but it apparently loaded before the trigger as It kept saying vehlist was undefined)

 

After this, the Ai squads still do not use the vehicles, even when under attack.

Can someone tell me where I went wrong?

Share this post


Link to post
Share on other sites

put the 2nd code back into an SQF and put this at the top, will stop that error

waituntil {sleep 3;(!isnil "vehList")};
  • Like 1

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

×