dist had better task getter

This commit is contained in:
Eero af Heurlin 2016-07-25 00:29:19 +03:00
parent 416d828d9d
commit a5e2b7cebe
2 changed files with 5 additions and 5 deletions

View File

@ -1,5 +1,5 @@
diag_log format["ejectSquad called, _this: %1", _this];
private _lz = _this select 0
private _lz = _this select 0;
private _vehicle = _this select 1;
private _squad = _this select 2;
private _fromTaskId = _this select 3;
@ -10,14 +10,14 @@ deleteWaypoint [_squad,1];
{unAssignVehicle _x} forEach units _squad;
{_x enableAI "TARGET"; _x enableAI "AUTOTARGET";} foreach units _squad;
private wp = _squad addwaypoint [_lz,5,1];
wp setwaypointType "MOVE";
private _wp = _squad addwaypoint [_lz,5,1];
_wp setwaypointType "MOVE";
scopeName "main";
while {true} do
{
scopeName "ejectloop";
if (((_x in _vehicle) && (alive _x)} count units _group) == 0) then
if (({(_x in _vehicle) && (alive _x)} count units _group) == 0) then
{
// No squad units left alive inside
[_fromTaskId, "SUCCEEDED" ,true] spawn BIS_fnc_taskSetState;

View File

@ -8,7 +8,7 @@ createDropoffLZ = compile preProcessfile "createDropoffLZ.sqf";
createSquad = compile preProcessfile "createSquad.sqf";
createEnemySquads = compile preProcessfile "createEnemySquads.sqf";
loadSquad = compile preProcessfile "loadSquad.sqf";
//ejectSquad = compile preProcessfile "ejectSquad.sqf";
ejectSquad = compile preProcessfile "ejectSquad.sqf";
deleteSquads = compile preProcessfile "deleteSquads.sqf";
playerVehicleInList = compile preProcessfile "playerVehicleInList.sqf";