diff --git a/src/scripts/server/patrols/manage_one_patrol.sqf b/src/scripts/server/patrols/manage_one_patrol.sqf index 62c7f72..10c48ac 100644 --- a/src/scripts/server/patrols/manage_one_patrol.sqf +++ b/src/scripts/server/patrols/manage_one_patrol.sqf @@ -1,5 +1,5 @@ params [ "_minimum_readiness", "_is_infantry" ]; -private [ "_headless_client" ]; +private [ "_headless_client", "_grp", "_spawn_marker", "_sector_spawn_pos", "_started_time", "_patrol_continue" ]; waitUntil { !isNil "blufor_sectors" }; waitUntil { !isNil "combat_readiness" }; @@ -58,6 +58,11 @@ while { GRLIB_endgame == 0 } do { }; while { _patrol_continue } do { + if (isNil "_grp") then { + _patrol_continue = false; + ["_grp was nil, but patrol was expected", "MANAGE_ONE_PATROL"] call KPLIB_fnc_log; + break; + }; sleep 60; if ( count (units _grp) == 0 ) then { _patrol_continue = false;