mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Allow defusing naval mines
Fix #4074 - Workaround for naval mines not working with deactivate - Add "isNotSwimming" exception to defuse progress bar
This commit is contained in:
parent
d249132864
commit
721bc205ef
@ -25,5 +25,12 @@ if (GVAR(ExplodeOnDefuse) && {(random 1.0) < (getNumber (ConfigFile >> "CfgAmmo"
|
||||
[QGVAR(explodeOnDefuse), [_explosive, _unit]] call CBA_fnc_globalEvent;
|
||||
};
|
||||
|
||||
_unit action ["Deactivate", _unit, _explosive];
|
||||
[QGVAR(defuse), [_explosive, _unit]] call CBA_fnc_globalEvent;
|
||||
|
||||
if (!(_explosive isKindOf "UnderwaterMine_Range_Ammo")) then {
|
||||
_unit action ["Deactivate", _unit, _explosive];
|
||||
} else {
|
||||
// Underwater naval mines don't seem to respond to the deactivate action
|
||||
// For now, lets just delete them
|
||||
deleteVehicle _explosive;
|
||||
};
|
||||
|
@ -63,6 +63,6 @@ if (ACE_player != _unit) then {
|
||||
_isEOD = [_unit] call EFUNC(Common,isEOD);
|
||||
_defuseTime = [_isEOD, _target] call _fnc_DefuseTime;
|
||||
if (_isEOD || {!GVAR(RequireSpecialist)}) then {
|
||||
[_defuseTime, [_unit,_target], {(_this select 0) call FUNC(defuseExplosive)}, {}, (localize LSTRING(DefusingExplosive))] call EFUNC(common,progressBar);
|
||||
[_defuseTime, [_unit,_target], {(_this select 0) call FUNC(defuseExplosive)}, {}, (localize LSTRING(DefusingExplosive)), {true}, ["isNotSwimming"]] call EFUNC(common,progressBar);
|
||||
};
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user