Skip to content

Commit

Permalink
logging for no spawn pos found
Browse files Browse the repository at this point in the history
  • Loading branch information
nomisum committed Mar 15, 2016
1 parent e8ddac4 commit 7b81f57
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion server/spawnBluforHQ.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,15 @@ spawnBluforHQ = {
} else {
hmmwv_hq = "rhsusf_m998_d_4dr";
};
_startTime = time;


while {_waitingForBluforSpawn} do {
_bluforSpawnSuccess = [0,nil,nil];
if (time > (_startTime + 60)) exitWith {
diag_log format ["fatal error : no blufor spawnpad position found"];
[{hintSilent "F A T A L E R R O R: no blufor spawn position found, please restart";},"BIS_fnc_spawn",true,true] call BIS_fnc_MP;
};

_bluforSpawnSuccess = [_bluforCenterPosition, [hmmwv_hq,"Land_HelipadCivil_F"], _bluforDistance] call testSpawnPositions;
waitUntil {(_bluforSpawnSuccess select 0) > 0};
Expand Down Expand Up @@ -206,15 +212,21 @@ spawnOpforHQ = {
_opforCenterPosition = _this select 0;
_opforDistance = _this select 1;
_waitingForOpforSpawn = true;

_startTime = time;

while {_waitingForOpforSpawn} do {
_opforSpawnSuccess = [0,nil,nil];

if (time > (_startTime + 60)) exitWith {
diag_log format ["fatal error : no opfor spawnpad position found"];
[{hintSilent "F A T A L E R R O R: no opfor spawnpad position found, please restart";},"BIS_fnc_spawn",true,true] call BIS_fnc_MP;
};

// landclutter instead of building - dummy object
_opforSpawnSuccess = [_opforCenterPosition, ["Land_ClutterCutter_small_F","Land_HelipadCivil_F"], _opforDistance] call testSpawnPositions;
waitUntil {(_opforSpawnSuccess select 0) > 0};


if ((_opforSpawnSuccess select 0) > 1) exitWith {
_waitingForOpforSpawn = false;

Expand Down

0 comments on commit 7b81f57

Please sign in to comment.