Jump to content
Sign in to follow this  
thefinn

How to make AI squad members use burst fire ?

Recommended Posts

I'm about 80% through making my own first mission, and I am wondering (about the topic) ;)

I've read some about full auto, but that's also more to do with OPFOR AI. I'm not sure if you can do something specific or even quite simple with squad members. It's annoying to see them using SMG's in single fire mode.

(also I use bcombat if that's relevant).

Thanks for any help.

Just to give some insight, the AI doesn't start the game with weapons, so something that can be applied outside of initialization would be good.

Edited by thefinn

Share this post


Link to post
Share on other sites
{
   _x addEventhandler ["fired", { 
       _unit = _this select 0;
       _weapon = _this select 1;
       _mode = _this select 3;
       _typeArray = [_weapon] call BIS_fnc_itemType;
       if ((_typeArray select 1) == "SubmachineGun" && {_mode != "Burst"}) then { // If the weapon fired is a sub machine gun and it's not on burst mode then...
           _unit action ["SWITCHMAGAZINE", _unit, _unit, 1]; // Switch the unit's weapon to burst mode. Can also use "SWITCHWEAPON" to change firing modes
       };
   }];  
} forEach allUnits; 

Edited by Iceman77

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  

×