Jump to content
Sign in to follow this  
Jacksaunt

Keeping AI crewman from disembarking a vehicle under damage

Recommended Posts

So I've made a very simple mission, it's just a bunch of tanks fighting each other, but I'm having some issues. Because I am using ACE, the tanks will only take some damage when hit. Sometimes after being hit the commander's M2 is broken, and the AI in charge of the tank platoon will tell the crewmen in the tank to disembark because of this. There are a few problems with this. One being that AI crewmen running around the battlefield is not what the mission is supposed to be. Two being after taking very low damage, your perfectly working tank is now useless because the AI told you to get out. I've searched some but nothing came up.

Share this post


Link to post
Share on other sites

Ooo. That's a new one. Should solve a regularly occurring issue.

Share this post


Link to post
Share on other sites

I haven't tried it, but couldn't you just lock the vehicle. Or will they just bypass the lock system and bail?

Share this post


Link to post
Share on other sites
. Or will they just bypass the lock system and bail?

They used to do that, they would bail regardless of lock, but it was changed in a patch a while back.

The problem with locking is that it prevents get in as well as getout, so this new command is very welcome.

Share this post


Link to post
Share on other sites

Locking the vehicle should work well for what the mission is, however a script is easier to apply to all the tanks.

I'm pretty new to scripting (real virtuality being the first real language I'm learning), how would I define _vehicle for allowcrewinmobile? I could do a group forEach but that would take a lot of work, or I could use getPos, which I don't really know how to use very well.

Share this post


Link to post
Share on other sites
;2258414']
{
private[_vehicle];
_vehicle = _x;
_vehicle allowCrewInImmobile true;
} forEach vehicles;

Ref: http://community.bistudio.com/wiki/vehicles

Thanks, didn't know that existed.

EDIT: Turns that still allows crew to bail when the vehicle is not able to shoot either, so I just added a setvehiclelock "locked" with forEach. Thanks for the help, will be useful.

Edited by Jacksaunt

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
Sign in to follow this  

×