Gromes Posted June 14, 2015 Report Share Posted June 14, 2015 I use script LSpawner and when i found weapon i can't find any ammo near. anyone know how to repair this problem ? Link to comment Share on other sites More sharing options...
0 Richie Posted June 14, 2015 Report Share Posted June 14, 2015 There's a fix in the LSpawner release thread, no idea where but i know it's there so have a read through :) Link to comment Share on other sites More sharing options...
0 1Man Posted June 14, 2015 Report Share Posted June 14, 2015 Cameltoe's 14 Apr 2015 V1va, on 12 Apr 2015 - 08:43 AM, said: So currently no way to spawn a gun with 1-3 mags of its specific ammo? I found a solution: in your fn_LSgetBuildingstospawnLoot.SQF find //special for weapons if(_lootType == 1) exitWith { _lootholder = createVehicle ["GroundWeaponHolder", _tmpPos, [], 0, "CAN_COLLIDE"]; _selecteditem = (floor(random(count((lootWeapon_list select _lootClass) select 1)))); _loot = (((lootWeapon_list select _lootClass) select 1) select _selecteditem); _lootholder addWeaponCargoGlobal [_loot, 1]; _lootholder setdir (random 360); _lootholder setPosATL _spwnPos; and right after that insert this //Function to add the right magazine for a weapon. _ammo = [] + getArray (configFile >> "cfgWeapons" >> _loot >> "magazines"); _lootholder addMagazineCargoGlobal [(_ammo select 0),(round(random 3))]; //max 3 magazines per weapon //end custom funtion _lootholder setdir (random 360); _lootholder setPosATL _spwnPos; where this (round(random 3) number defines how many magazines will spawn. Link to comment Share on other sites More sharing options...
Question
Gromes
I use script LSpawner and when i found weapon i can't find any ammo near. anyone know how to repair this problem ?
Link to comment
Share on other sites
2 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now