Epoch_Server/Server/@epochhive/addons/ud/fn_deploymozzie.sqf
2020-02-18 09:55:40 -07:00

20 lines
599 B
Plaintext

if(isServer) then {
"UDMOZZIE" addPublicVariableEventHandler {_this select 1 call Spawn_Mozzie};
Spawn_Mozzie = {private["_playerObj","_spawnPos","_spawnDir","_veh","_goat"];
_playerObj = _this select 0;
_spawnPos = _this select 1;
_spawnDir = _this select 2;
_veh = createVehicle["Mosquito_Epoch", _spawnPos, [], 0, "NONE"];
_veh allowDamage false;
_veh setPos _spawnPos;
_veh setDir _spawnDir;
_veh setVectorUp (surfaceNormal (getPos _veh));
_veh call EPOCH_server_setVToken;
_veh call EPOCH_server_vehicleInit;
_veh setVelocity [0,0,.1];
_veh allowDamage true;
};
};