-
Notifications
You must be signed in to change notification settings - Fork 1
Installation and Usage
This is a small set of instructions of how to install the script to your mission.
Either clone this repository, download it as zip or downlod the latest release (recommended). Once you downloaded the script unpack it and renname the main directory to freestylesNuclearBlast. This directory should contain everything else (including cfgFunction.hpp).
Now open your mission's directory and move or copy the freestylesNuclearBlast directory into it.
In your mission's directory (not inside freestylesNuclearBlast) create a file named description.ext. If you already have one skip this step.
If your description.ext already contains a CfgFunctions class add this code inside of it:
#include "freestylesNuclearBlast\cfgFunctions.hpp"
If there is no CfgFunctions class or you just created description.ext in the previous step add this code to the file:
class CfgFunctions
{
#include "freestylesNuclearBlast\cfgFunctions.hpp"
};
The blast is initiated using the freestylesNuclearBlast_fnc_initBlast function. This function has to be spawned and should only run on the server in multiplayer (on clients it will automaticly exit without causing any issues).
freestylesNuclearBlast_fnc_initBlast needs at least two arguments passed to it in order to create an explosion. The other arguments are optional. All arguments are passed as an array:
0 - positionASL, blast origin position
1 - number, yield in kT of TNT equivalent
2 - bool, wether to output debug infomation or not, includes map markers and text output, default: true
3 - array of bools, enbale different effects and damage types, default: all true
0 - crater generation
1 - blast wave damage, includes 20, 5 and 1 psi effects
2 - direct radiation damage, including thermal and nuclear effects
3 - smoke pillar effects
4 - dust wave effect
5 - sound effects
6 - fireball and light
7 - condensation rings
8 - lingering smoke around detonation origin
9 - mushroom cloud
4 - number, fire propability (form 0 to 1), use -1 to disable, default: 0.1 5 - number, duration of radiation zone around blast area in minutes, -1 to disable, default: -1
Simple exlosion at [1201, 1201, 40] with 10 kT TNT equivalent:
[[1201, 1201, 40], 10] spawn freestylesNuclearBlast_fnc_initBlast
Same explosion without debug:
[[1201, 1201, 40], 10, false] spawn freestylesNuclearBlast_fnc_initBlast
Blowing up an object called bob with 25 kT of TNT but without a crater:
[getPosASL bob, 25, false, [false, true, true, true, true, true, true, true, true, true]]
Blowing up bob and burning every building possible:
[getPosASL bob, 25, false, [false, true, true, true, true, true, true, true, true, true], 1]
Blowing up bob and burning no building at all:
[getPosASL bob, 25, false, [false, true, true, true, true, true, true, true, true, true], -1]
Blowing up bob without any visual effect:
[getPosASL bob, 25, false, [false, true, true, false, false, false, false, false, false, false], -1]
Blowing up bob with only visual and no damage (except fires to 20 % of the possible buildings):
[getPosASL bob, 25, false, [false, false, false, true, true, true, true, true, true, true], 0.2]
Blowing up bob with only visual and no damage (except fires to 20 % of the possible buildings) and 5 minutes radioation:
[getPosASL bob, 25, false, [false, false, false, true, true, true, true, true, true, true], 0.2, 5]