Jump to content
Tankbuster

AI dont engage after setcombatmode red

Recommended Posts

Guys,

One of my secondary missions (it's already a behemoth, 600+ lines of code and still going, might release it as a standalone) has players manning a roadblock. Some of the vehicle encounters are friendly, some enemy, it's random.

 

Enemy vehicles drive to a move waypoint with setwaypointtcombatmode blue just outside the RB and they wait there. If players get close or shoot at the AI, the AI are setcombatmode red and the nearest player is revealed to the ai group, but they don't bail or engage.

I tried giving all of the crew who aren't gunners a dogetout and they do that, but they rarely engage players. They often mince about a bit then get back in the vec.

If the vec is an MG technical, the gunner engages immediately .

 

Why don't the AI bail and start shooting the moment I set them to combatmode red?

Share this post


Link to post
Share on other sites
On 7/20/2019 at 8:09 PM, RCA3 said:

Hey,

canUnloadInCombat

setUnloadInCombat

?

 

You might also need:


{
   unassignVehicle _x;

   [_x] orderGetIn false;

}forEach assignedCargo (vehicle);

 

Yes, I'm doing that.

_rbvec setUnloadInCombat [true, true];

I'll try the other code now.

Share this post


Link to post
Share on other sites

Resolved. @Tankbuster was using behaviour CARELESS on the waypoint. Upon dismount, their behaviour had to be changed back to COMBAT.

  • Like 1
  • Haha 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

×