mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
VehicleSetFuel event
setFuel says it needs to be local, so switching to event. Put event in common
This commit is contained in:
parent
4b1e40570e
commit
9a616a85fc
@ -134,3 +134,8 @@ GVAR(OldPlayerTurret) = [ACE_player] call FUNC(getTurretIndex);
|
||||
[QGVAR(StateArrested),false,true,QUOTE(ADDON)] call FUNC(defineVariable);
|
||||
[QGVAR(carriedBy),objNull,false,QUOTE(ADDON)] call FUNC(defineVariable);
|
||||
[QGVAR(carriedObj),objNull,false,QUOTE(ADDON)] call FUNC(defineVariable);
|
||||
|
||||
["VehicleSetFuel", {
|
||||
PARAMS_2(_vehicle,_fuelLevel);
|
||||
_vehicle setFuel _fuelLevel;
|
||||
}] call FUNC(addEventhandler);
|
||||
|
@ -20,8 +20,8 @@ if (!(_this call FUNC(canRefuelUAV))) exitWith {};
|
||||
|
||||
_onFinish = {
|
||||
EXPLODE_2_PVT((_this select 0),_caller,_target);
|
||||
_target setFuel 1;
|
||||
_caller removeItem "ACE_UAVBattery";
|
||||
["VehicleSetFuel", [_target], [_target, 1]] call EFUNC(common,targetEvent); //setFuel is local
|
||||
};
|
||||
|
||||
_onFailure = {
|
||||
|
Loading…
Reference in New Issue
Block a user