Switching seats in flight.

drmagnumwolf

New Member
I'm curious if anyone can help me, my scripting abilities are VERY limited. I found 2 to 3 scripts which allows you to switch seats in a helicopter in flight over the internet.

I'm trying to make it so the helicopter stays in autohover when you switch it. The only thing I've managed to do is that every time a switch happens to the pilot seat the autohover turns on. I need to force it like it does with the engine(which is working fine)

I'm asking for help because I hate some of the gunners that I get, and most of the time I like to troll around and scare them my fellow admins. (player base is strictly forbidden, to avoid abuse and because it is a "bit" overpowered).

Can anyone help me?

I found this script in http://forums.bistudio.com/showthread.php?125795-AH64-Gunner-Script


Code:
// Add the folowing two addaction commands to the init of the chopper, save script as "swap_seat.sqf"
//
// this addAction ["To Gunner Seat","swap_seat.sqf",[],1,false,true,"","( driver _target == _this)"];
// this addAction ["To Pilot Seat","swap_seat.sqf",[],1,false,true,"","( gunner _target == _this)"];
 
_veh = _this select 0;
_unit = _this select 1;
 
_gunner = gunner _veh;
_driver = driver _veh;
 
_engine = isengineon _veh;
 
 
if ([assignedVehicleRole _unit, ["driver"]] call BIS_fnc_areEqual) then {
      _gunner setpos [0,0,0];
      _driver setpos [0,0,0];
      _driver moveingunner _veh;
      _gunner moveindriver _veh;
  } else {
      _driver setpos [0,0,0];
      _gunner setpos [0,0,0];
      _gunner moveindriver _veh;
      _driver moveingunner _veh;
};
 
_veh engineon _engine; // AI won't turn engine on unless they have a destination this forces it on
_veh action ["AutoHover", _veh]
 
Back
Top