From e353f2b88b45af7455494b299ec053d0053a88c9 Mon Sep 17 00:00:00 2001 From: Tom Date: Fri, 30 Oct 2020 22:27:56 +0100 Subject: [PATCH] fix undefined _alive --- addons/airway/XEH_postInit.sqf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/airway/XEH_postInit.sqf b/addons/airway/XEH_postInit.sqf index 66b7316b5..4be639f2b 100644 --- a/addons/airway/XEH_postInit.sqf +++ b/addons/airway/XEH_postInit.sqf @@ -12,7 +12,9 @@ if !(GVAR(enable)) exitWith {}; if !(_state) exitWith { _unit call FUNC(init); }; - if (!_alive && (_unit getVariable [GVAR(string_exit), false])) exitWith {}; + + private _alive = alive _unit; + if ((!_alive) || (_unit getVariable [GVAR(string_exit), ""] isEqualTo "keko_wasPunched")) exitWith {}; if (EGVAR(breathing,enable)) then { ["handleBreathing", [_unit, CBA_missionTime], _unit] call CBA_fnc_targetEvent; };