Jump to content
aussie battler

Ban player ai from getting in the chopper's gunner seat.

Recommended Posts

Is there a way to add an eventhandler to disallow player ai getting into gunner?

Players are taking advantage of the ai targeting sytem. They fly a chopper with ai in gunner. Ai will target a player (but wont fire), players then switch to gunner & let hell rain.

I am wondering if ther is some sort of event handler to ban an ai getting in the chopper's gunner seat?


// in the spawn ai code:

while {true} do {
if vehicle player isKindOf "helicopter"; 
[_soldier1] allowGetIn false;


Share this post

Link to post
Share on other sites


in initPlayerLocal.sqf


player addEventHandler ["SeatSwitchedMan", {
  params ["_unit1", "_unit2", "_vehicle"];
  systemChat str [_unit1,_unit2, assignedVehicleRole _unit1, assignedVehicleRole _unit2];
  if (_vehicle isKindOf "helicopter") then {
    if (toLowerANSI getText (configFile / "cfgWeapons" / (_vehicle currentWeaponTurret (_vehicle unitTurret _unit1))/ "nameSound") in ["mgun","cannon"]) then {
      hint "You can't switch to this seat!";


Do what you want for kick or ban player... I don't have this kind of script.


  • Like 2

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