Animated Helicrashs 0.1 - Release

In the case of using static cords
What exactly are 3 of these? Is this the list of crash positions?

//_staticcoords = [[6277.5605,8332.8262],[1234.5605,4321.8262],[45545.5605,1256.8262]];

And is it possible to set up the start position for any given crash position?
 
In the case of using static cords
What exactly are 3 of these? Is this the list of crash positions?

//_staticcoords = [[6277.5605,8332.8262],[1234.5605,4321.8262],[45545.5605,1256.8262]];

And is it possible to set up the start position for any given crash position?
Yip, these are 3 random positions anywhere (let my cat jump over the numblock), just exchange them with your custom 2D-Coordinates.

For now the startposition of the heli can only be random, but it would be easy to add one more dimension to the array, so every entry can have a start and end-position... but do you think this is realy needed? I like that every flight is a little bit random, this way you never know what happens....
 
Code:
5 setDamage !"\"setDamage\"," !"_vehicle setDamage 0;" !"player setdamage 0;" !"if (alive player) then { player SetDamage 1;};" !"if (_ent isKindOf \"Animal\") then {\n_ent setDamage 1;" !"player setDamage 1;\n0.1 fadeSound 0;"

thats the line causing the kick i guess, cause after removed the setdamage command from the

Code:
    "heliCrash"    addPublicVariableEventHandler {
        _list = nearestObjects [_this select 1, ["CraterLong"], 100];
        {_x setdamage 1; deleteVehicle _x;} foreach _list;
    };

kicks didnt happen anymore, it just wont clean up the craters but thats np for me


anyways.. thank you so much for this script.. love it

danke! :D

ps: yeah that would be epic sarge :O
Kicks will happen whenever a heli is crashing (for everyone on the server), so if you like to stay with the rocks, then delete the code from your init.sqf, otherwise you should change your scripts.txt as sarge wrote :)
 
Nope, just copy it like i wrote it... or just try & error, there are only 2 possible ways, sometimes its faster to just try something then asking for an answer ;)
 
Nope, just copy it like i wrote it... or just try & error, there are only 2 possible ways, sometimes its faster to just try something then asking for an answer ;)

Sorry for all the questions but when you say exchange the downloaded file for the spawn_crashsite file, would I have to exchange it with the server_monitor instead?
 
//_staticcoords = [[6277.5605,8332.8262],[1234.5605,4321.8262],[45545.5605,1256.8262]];

OP can you please post your static coords for Chernarus? Even supply them in main thread to make some peoples lives easier who just want working default positions (like they were before --- Open fields only, etc)

At least i think im understanding it right, that those are the coords in which the heli's crash.

Thanks for this man
 
A pretty basic fix for DayZCC. Not really proud of it but it works. If someone is unfamiliar with the files and has some skills, pls take a look: https://github.com/Crosire/DayZ-Private-Source/tree/master/server/dayz_server.

Meanwhile...
To make it work:

Replace all the code in server_spawnWreck.sqf with the code provided by Grafzahl.
Change the first lines from:

Code:
//_crashModel    = _this select 0;
//_lootTable    = _this select 1;
_guaranteedLoot = _this select 0;
_randomizedLoot = _this select 1;
_frequency    = _this select 2;
_variance    = _this select 3;
_spawnChance    = _this select 4;
_spawnMarker    = _this select 5;
_spawnRadius    = _this select 6;
_spawnFire    = _this select 7;
_fadeFire    = _this select 8;

to:

Code:
_guaranteedLoot = _this select 2;
_randomizedLoot = _this select 2;
_frequency        = _this select 3;
_variance        = _this select 4;
_spawnChance    = _this select 5;
_spawnMarker    = _this select 6;
_spawnRadius    = _this select 7;
_spawnFire        = _this select 8;
_fadeFire        = _this select 9;

Next go to server_monitor.sqf and change the line:

Code:
if (SpawnHelis && worldName != "namalsk") then {
    if (OldSpawn) then {
        for "_x" from 1 to SpawnHelisCount do { _id = [] spawn spawn_helis; };
    } else {
        [["UH60Wreck_DZ", "UH1Wreck_DZ"], ["Military", "HeliCrash", "MilitarySpecial"], SpawnHelisCount, (50 * 60), (15 * 60), 0.75, 'center', 4000, true, false] spawn server_spawnWreck;
    };
};

to:

Code:
if (SpawnHelis && worldName != "namalsk") then {
    if (OldSpawn) then {
        for "_x" from 1 to SpawnHelisCount do { _id = [] spawn spawn_helis; };
    } else {
        [["UH1Wreck_DZ", "Mi8Wreck"], ["Military", "HeliCrash", "MilitarySpecial"], 4, (50 * 60), (15 * 60), 0.75, 'center', 4000, true, false] spawn server_spawnWreck;
    };
};

U may change it to 4, 60, 0, 1, 'center', 4000, true, false] spawn server_spawnWreck; for testing purposes.

finally make sure you have set

Code:
#define OldSpawn false

in dayz_server_config.hpp

Now one problem which I encountered with this "hack" is that the modified chances only apply to the first Heli spawn:

Code:
 2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 100% chance to spawn 'Mi17_DZ' with loot table 'MilitarySpecial' at 60"
2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 75% chance to spawn 'UH-1H' with loot table 'HeliCrash' at 3676"
2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 75% chance to spawn 'Mi17_DZ' with loot table 'HeliCrash' at 3512"

But it works, The Heli flies, crashes, spawns loot etc.
As I said, I anyone want's to make it better, feel free to do so ;)
 
Ok i dont understand what you are trying to say here

Now one problem which I encountered with this "hack" is that the modified chances only apply to the first Heli spawn:

Code:
 2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 100% chance to spawn 'Mi17_DZ' with loot table 'MilitarySpecial' at 60"
2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 75% chance to spawn 'UH-1H' with loot table 'HeliCrash' at 3676"
2:57:52 "CRASHSPAWNER: Starting spawn logic for Crash Spawner"
2:57:52 "CRASHSPAWNER: 75% chance to spawn 'Mi17_DZ' with loot table 'HeliCrash' at 3512"

Can you please be a little more clear? im sorry
 
I've got to say, I just added this, and it was on of the most amazing sights I've seen. Thank you so much for your contribution.
 
Back
Top