From 6591e71d10311adc9f5fd94209107f5213984283 Mon Sep 17 00:00:00 2001 From: McDiod Date: Sun, 13 Mar 2016 13:28:12 +0100 Subject: [PATCH] detect_all_dead.sqf fix maybe --- objectives/detect_all_dead.sqf | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/objectives/detect_all_dead.sqf b/objectives/detect_all_dead.sqf index cc692d4e..06c5f93f 100644 --- a/objectives/detect_all_dead.sqf +++ b/objectives/detect_all_dead.sqf @@ -2,15 +2,16 @@ if (!isServer) exitWith {}; checkForReal = { - _bool = compile (_this select 0); - + _varName = _this select 0; + _bool = call compile (_this select 0); + for [{_i=0}, {_i<20}, {_i=_i+1}] do { if (!_bool) exitWith {}; sleep 1; }; - if (_bool && str _bool == "OPFOR_PRE_ELIMINATED") then {OPFOR_ELIMINATED = true;}; - if (_bool && str _bool == "BLUFOR_PRE_ELIMINATED") then {BLUFOR_ELIMINATED = true;}; + if (_bool && _varName == "OPFOR_PRE_ELIMINATED") then {OPFOR_ELIMINATED = true;}; + if (_bool && _varName == "BLUFOR_PRE_ELIMINATED") then {BLUFOR_ELIMINATED = true;}; }; [] spawn {