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

@@ -15,7 +15,7 @@ _agent = objNull;
_type = _unitTypes call BIS_fnc_selectRandom;
//Create the Group and populate it
//Create the Group && populate it
//diag_log ("Spawned: " + _type);
_radius = 40;
_method = "NONE";
@@ -64,7 +64,7 @@ if (_rnd > 0.3) then {
_array = [];
{
_array set [count _array, _x select 0]
} foreach _lootTypeCfg;
} count _lootTypeCfg;
if (count _array > 0) then {
_index = dayz_CLBase find _lootType;
_weights = dayz_CLChances select _index;