mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Added vehicle existance check
This commit is contained in:
parent
05c16a5dfb
commit
5b4072bf50
@ -6,6 +6,7 @@ PREP(canCutRopes);
|
||||
PREP(canDeployRopes);
|
||||
PREP(canFastRope);
|
||||
PREP(canPrepareFRIES);
|
||||
PREP(checkVehicleThread);
|
||||
PREP(cutRopes);
|
||||
PREP(deployRopes);
|
||||
PREP(equipFRIES);
|
||||
|
25
addons/fastroping/functions/fnc_checkVehicleThread.sqf
Normal file
25
addons/fastroping/functions/fnc_checkVehicleThread.sqf
Normal file
@ -0,0 +1,25 @@
|
||||
/*
|
||||
* Author: BaerMitUmlaut
|
||||
* Checks if the given helicopter still exits, and if not, destroys the FRIES.
|
||||
*
|
||||
* Arguments:
|
||||
* 0: The helicopter <OBJECT>
|
||||
* 1: The helicopter's FRIES <OBJECT>
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
*
|
||||
* Example:
|
||||
* [_vehicle, _fries] call ace_fastroping_fnc_checkVehicleThread
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
#include "script_component.hpp"
|
||||
params ["_vehicle", "_fries"];
|
||||
|
||||
if (isNull _vehicle) then {
|
||||
deleteVehicle _fries;
|
||||
} else {
|
||||
[FUNC(checkVehicleThread), _this, 5] call EFUNC(common,waitAndExecute);
|
||||
};
|
@ -35,5 +35,6 @@ if !(isNumber (_config >> QGVAR(enabled))) then {
|
||||
[_vehicle] call FUNC(cutRopes);
|
||||
};
|
||||
}];
|
||||
[FUNC(checkVehicleThread), [_vehicle, _fries], 5] call EFUNC(common,waitAndExecute);
|
||||
};
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user