mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Replaced sleep with waitAndExecute
This commit is contained in:
parent
b4c057919e
commit
e8264110bb
@ -43,15 +43,15 @@ if (ACE_player != _unit) then {
|
||||
if (isPlayer _unit) then {
|
||||
[[_unit, _target], QFUNC(startDefuse), _unit] call EFUNC(common,execRemoteFnc);
|
||||
} else {
|
||||
// TODO: use scheduled delay execution
|
||||
[_unit, _target, [[_unit] call EFUNC(Common,isEOD), _target] call _fnc_DefuseTime] spawn {
|
||||
(_this select 0) playActionNow _actionToPlay;
|
||||
(_this select 0) disableAI "MOVE";
|
||||
(_this select 0) disableAI "TARGET";
|
||||
sleep (_this select 2);
|
||||
[(_this select 0), (_this select 1)] call FUNC(defuseExplosive);
|
||||
(_this select 0) enableAI "MOVE";
|
||||
(_this select 0) enableAI "TARGET";
|
||||
[{
|
||||
[(_this select 0), (_this select 1)] call FUNC(defuseExplosive);
|
||||
(_this select 0) enableAI "MOVE";
|
||||
(_this select 0) enableAI "TARGET";
|
||||
}, _this, (_this select 2), 0] call EFUNC(common,waitAndExecute);
|
||||
};
|
||||
};
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user