Replace forEach with Count

Use count where you do not need _forEachIndex variable, it's quicker
than forEach.
This commit is contained in:
icomrade
2014-05-27 15:37:57 -04:00
parent 91d246e64e
commit e54b9983dd
210 changed files with 890 additions and 890 deletions

View File

@@ -9,10 +9,10 @@ while {_run} do {
_nearby = false;
{
if (_x distance _building < 500) then {_nearby = true};
} forEach (call BIS_fnc_listPlayers);
} count (call BIS_fnc_listPlayers);
if (!_nearby) then {_run = false};
sleep 5;
};
{deleteVehicle _x;} forEach _items;
{deleteVehicle _x;} count _items;
_building setVariable ["looted",(DateToNumber date),true];