Huey Crash Spawn Amounts

Forgotten

Well-Known Member
I've been trying to get a larger amount of crashed choppers spawning so people don't camp the airfields non stop and have more organic fights out in the country instead of snipe/get sniped at airfield.

To that end, I was pointed to this in the server.pbo under server_monitor.

//Spawn crashed helos
for "_x" from 10 to 12 do {
_id = [] spawn spawn_heliCrash;
//waitUntil{scriptDone _id};
};

I changed it from "1 to 5" to the above. It seems to do nothing.

I also found this in server_functions:

spawn_heliCrash = {
private["_position","_veh","_num","_config","_itemType","_itemChance","_weights","_index","_iArray"];

waitUntil{!isNil "BIS_fnc_selectRandom"};
if (isDedicated) then {
_position = [getMarkerPos "center",0,4000,10,0,2000,0] call BIS_fnc_findSafePos;
_veh = createVehicle ["UH1Wreck_DZ",_position, [], 0, "CAN_COLLIDE"];
dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_veh];
_veh setVariable ["ObjectID",1,true];
dayzFire = [_veh,2,time,false,false];
publicVariable "dayzFire";
if (isServer) then {
nul=dayzFire spawn BIS_Effects_Burn;
};
_num = round(random 10) + 3;
_config = configFile >> "CfgBuildingLoot" >> "HeliCrash";
_itemType = [] + getArray (_config >> "itemType");
//diag_log ("DW_DEBUG: _itemType: " + str(_itemType));
_itemChance = [] + getArray (_config >> "itemChance");
//diag_log ("DW_DEBUG: _itemChance: " + str(_itemChance));
//diag_log ("DW_DEBUG: (isnil fnc_buildWeightedArray): " + str(isnil "fnc_buildWeightedArray"));

waituntil {!isnil "fnc_buildWeightedArray"};

_weights = [];
_weights = [_itemType,_itemChance] call fnc_buildWeightedArray;
//diag_log ("DW_DEBUG: _weights: " + str(_weights));
for "_x" from 1 to _num do {
//create loot
_index = _weights call BIS_fnc_selectRandom;
sleep 1;
if (count _itemType > _index) then {
//diag_log ("DW_DEBUG: " + str(count (_itemType)) + " select " + str(_index));
_iArray = _itemType select _index;
_iArray set [2,_position];
_iArray set [3,5];
_iArray call spawn_loot;
_nearby = _position nearObjects ["WeaponHolder",20];
{
_x setVariable ["permaLoot",true];
} forEach _nearBy;
};
};
};
};
I changed _num = round(random 10) + 3; where 10 was 1. Also nothing seems to have changed.

A couple months back, I had 18 repairable hueys on the server. It seemed then the amount of chopper crashes was huge. Did that have anything to do with it? Frankly, I'm not sure, I was on Anti-rocket back then, and who knows.

Does anyone have a definitive answer about how to increase chopper crash numbers?
 
Bumping this, as I still have no valid answer. My server is now closed to the public as I work on it until standalone releases.

Since I have no players atm, I have spawned all of my choppers in, replacing some with rMod choppers. But, since the number of choppers is quite high, the amount of lootable chopper crashes has also skyrocketed. In no time I will find five or six crashes, where when I only had six chopper spawned, I would be hard pressed to find a single crash.
 
//Spawn crashed helos
for "_x" from 1 to 12 do {
_id = [] spawn spawn_heliCrash;
//waitUntil{scriptDone _id};
};

Replace this in your server_functions.sqf
 
//Spawn crashed helos
for "_x" from 1 to 12 do {
_id = [] spawn spawn_heliCrash;
//waitUntil{scriptDone _id};
};

Replace this in your server_functions.sqf

As I mentioned as something I already tried, it does not actually work. I had that in place for a month, flew around at server start many many times, found very few crashes. I had mine set to 10-15, so I should have been falling over them everywhere.
 
I did not find it on new version, I cannot see any crash site on my server... vehicles I fixed...but i'd like to see more helicrash sites on server too.

Tks guys!!

Ps: My server is Chernarus...
 
Hi,
I am new to all this, but have found this place very helpful.

Can someone here explain how to revert the crashed-choppers system back to the old style (assuming that is actually possible)? [specific to the pwn serverbuild]

Thanks guys!
 
as hms, i have the same problem with not having any crash sites at all on my server (or at least no one have found any the last two days) since i updated to 1.7.6.(1)

How can i check if there is any spawned on the map, and how can i change/fix it if it actually dont spawn on my server at all?
 
Back
Top