diff --git a/dayz_code/compile/building_spawnLoot.sqf b/dayz_code/compile/building_spawnLoot.sqf index d45c7b1e1..88bd5c44f 100644 --- a/dayz_code/compile/building_spawnLoot.sqf +++ b/dayz_code/compile/building_spawnLoot.sqf @@ -2,6 +2,7 @@ private["_obj","_type","_config","_positions","_iPos","_nearBy","_itemType","_it _obj = _this select 0; _type = typeOf _obj; +diag_log format["Spawning loot for: %1", _type]; _config = configFile >> "CfgBuildingLoot" >> _type; _positions = [] + getArray (_config >> "lootPos"); _itemTypes = [] + getArray (_config >> "itemType"); @@ -12,6 +13,7 @@ _lootChance = getNumber (_config >> "lootChance"); _nearBy = nearestObjects [_iPos, ["WeaponHolder","WeaponHolderBase"], 1]; if (count _nearBy == 0) then { _index = dayz_CBLBase find _type; + diag_log format["Found %2 at index: %1", _index,_type]; _weights = dayz_CBLChances select _index; _cntWeights = count _weights; _index = floor(random _cntWeights);