Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ////////////////////////////////////////////////////////////////////////////////////////
- // DayZ Air Raid written by //
- // mmmyum with work from //
- // sirens: http://www.armaholic.com/page.php?id=12598 by DarkXess //
- // bombs: http://www.armaholic.com/page.php?id=15612 by Maxjoiner //
- // modified by squeezer //
- ////////////////////////////////////////////////////////////////////////////////////////
- /////////////////////////SETUP repeat and break
- private ["_espl","_sound","_pos2","_pos2cnt","_seconds","_rndLoc","_place","_position","_choice","_duration","_xpos","_ypos","_targetpos","_loc","_target","_pos","_siren","_pos1","_choise","_ray","_dblsecs","_repeat","_break"];
- sleep 10;
- _repeat = 30; //times to repeat
- _break = 120; //time to break between attacks
- _position = [13135.9, 10393.3, 1.5]; //leave this
- _xpos = 13135.9;
- _ypos = 10393.3;
- _ray = 120;
- //repeat script
- diag_log format ["AIRRAID: Starting..."];
- sleep 2;
- While {_repeat > 1} do {
- /////////////////////////SETUP position
- // enter positions below. format x,y,z
- _rndLoc=floor(random 49);
- _place=
- switch (_rndLoc) do
- {
- case 0: {"BalottaAirstrip"};
- case 1: {"Berenzino"};
- case 2: {"Bereznio2"};
- case 3: {"BlackMountain"};
- case 4: {"Bor"};
- case 5: {"Cherno"};
- case 6: {"DevilsCastle"};
- case 7: {"DonsCamp"};
- case 8: {"Drozhino"};
- case 9: {"Dubrovka"};
- case 10: {"Electro"};
- case 11: {"Factory"};
- case 12: {"Gorka"};
- case 13: {"Grishno"};
- case 14: {"Guglovo"};
- case 15: {"Gvozdno"};
- case 16: {"Kabanino"};
- case 17: {"Kamyshovo"};
- case 18: {"Khelm"};
- case 19: {"Komarovo"};
- case 20: {"Kozlovka"};
- case 21: {"Krastonav"};
- case 22: {"Lopatino"};
- case 23: {"Moglievka"};
- case 24: {"Msta"};
- case 25: {"Myshkino"};
- case 26: {"Nadezhdino"};
- case 27: {"NEAF"};
- case 28: {"Nizhnoye"};
- case 29: {"NovySobor"};
- case 30: {"NWAF"};
- case 31: {"Orlovets"};
- case 32: {"Pavlovo"};
- case 33: {"Petrovka"};
- case 34: {"Pogorevka"};
- case 35: {"Polana"};
- case 36: {"Prigorodki"};
- case 37: {"Pulkovo"};
- case 38: {"Pusta"};
- case 39: {"Pustoshka"};
- case 40: {"Rogovo"};
- case 41: {"Shakhovka"};
- case 42: {"Solnichny"};
- case 43: {"Soosnovka"};
- case 44: {"Staroye"};
- case 45: {"StarySobor"};
- case 46: {"Tulga"};
- case 47: {"Vybor"};
- case 48: {"Vyshnoye"};
- case 49: {"Zelenogorsk"};
- };
- diag_log format ["AIRRAID: Random Location: %1 | %2",_rndLoc,_place];
- _position=
- switch (_rndLoc) do
- {
- case 0: {[4829.9868, 2450.1104, 1.5]};
- case 1: {[12954.624, 9783.1533, 1.5]};
- case 2: {[12043.963, 9091.3477, 1.5]};
- case 3: {[10276.416, 12049.6640, 1.5]};
- case 4: {[3320.1643, 3938.3496, 1.5]};
- case 5: {[6743.8853, 2581.1865, 1.5]};
- case 6: {[6891.9189, 11438.73, 1.5]};
- case 7: {[7788.2856, 12613.048, 1.5]};
- case 8: {[3442.2849, 4955.7129, 1.5]};
- case 9: {[10445.011, 9868.9912, 1.5]};
- case 10: {[10480.69, 2217.8027, 1.5]};
- case 11: {[13060.078, 7094.0596, 1.5]};
- case 12: {[9659.084, 8795.334, 1.5]};
- case 13: {[5979.6953, 10343.341, 1.5]};
- case 14: {[8517.8682, 6676.3276, 1.5]};
- case 15: {[8614.4316, 11868.967, 1.5]};
- case 16: {[5318.8369, 8602.6328, 1.5]};
- case 17: {[12127.406, 3496.2185, 1.5]};
- case 18: {[12290.833, 10904.328, 1.5]};
- case 19: {[3654.0908, 2475.9468, 1.5]};
- case 20: {[4483.6777, 4616.1675, 1.5]};
- case 21: {[11212.624, 12256.609, 1.5]};
- case 22: {[2780.3135, 10018.82, 1.5]};
- case 23: {[7544.5845, 5148.7822, 1.5]};
- case 24: {[11275.323, 5495.4053, 1.5]};
- case 25: {[2019.2487, 7327.7178, 1.5]};
- case 26: {[5846.4434, 4706.708, 1.5]};
- case 27: {[12073.906, 12724.305, 1.5]};
- case 28: {[13002.393, 8285.8574, 1.5]};
- case 29: {[7074.4854, 7683.4883, 1.5]};
- case 30: {[4480.0781, 10375.544, 1.5]};
- case 31: {[12146.174, 7266.5801, 1.5]};
- case 32: {[1693.9392, 3845.0657, 1.5]};
- case 33: {[5014.1143, 12493.039, 1.5]};
- case 34: {[4473.5957, 6411.3198, 1.5]};
- case 35: {[10753.393, 8132.6606, 1.5]};
- case 36: {[7976.5557, 3299.5386, 1.5]};
- case 37: {[4915.0903, 5605.6401, 1.5]};
- case 38: {[9156.2549, 3897.7598, 1.5]};
- case 39: {[3072.9629, 7945.4404, 1.5]};
- case 40: {[4808.0024, 6805.0518, 1.5]};
- case 41: {[9654.5244, 6555.2583, 1.5]};
- case 42: {[13454.279, 6233.647, 1.5]};
- case 43: {[2528.7561, 6354.9839, 1.5]};
- case 44: {[10140.659, 5434.4302, 1.5]};
- case 45: {[6143.6167, 7721.5176, 1.5]};
- case 46: {[12803.296, 4450.7466, 1.5]};
- case 47: {[3815.0635, 8865.0938, 1.5]};
- case 48: {[6590.3159, 6029.1128, 1.5]};
- case 49: {[2758.7144, 5304.3457, 1.5]};
- };
- _ray =
- switch (_rndLoc) do
- {
- case 0: {120};
- case 1: {120};
- case 2: {120};
- case 3: {120};
- case 4: {120};
- case 5: {120};
- case 6: {120};
- case 7: {120};
- case 8: {120};
- case 9: {120};
- case 10: {120};
- case 11: {120};
- case 12: {120};
- case 13: {120};
- case 14: {120};
- case 15: {120};
- case 16: {120};
- case 17: {120};
- case 18: {120};
- case 19: {120};
- case 20: {120};
- case 21: {120};
- case 22: {120};
- case 23: {120};
- case 24: {120};
- case 25: {120};
- case 26: {120};
- case 27: {120};
- case 28: {120};
- case 29: {120};
- case 30: {120};
- case 31: {120};
- case 32: {120};
- case 33: {120};
- case 34: {120};
- case 35: {120};
- case 36: {120};
- case 37: {120};
- case 38: {120};
- case 39: {120};
- case 40: {120};
- case 41: {120};
- case 42: {120};
- case 43: {120};
- case 44: {120};
- case 45: {120};
- case 46: {120};
- case 47: {120};
- case 48: {120};
- case 49: {120};
- };
- //////////////////////////SETUP type of bombing and duration
- _choice = 1;
- _duration = 60;
- /////////////////////////
- _xpos = _position select 0;
- _ypos = _position select 1;
- _targetpos = [_xpos, _ypos, 1.5];
- _loc = createVehicle ["HeliHEmpty", _targetpos,[], 0, "NONE"];
- _target = createVehicle ["HeliHEmpty",position _loc,[], 0, "NONE"]; // target bombing
- sleep 2;
- diag_log format ["AIRRAID: INCOMING ATTACK: Sounding Siren at: %1 %2 | Repeat: %3| Type: %4 | Duration: %5",_xpos,_ypos,_repeat,_choice,_duration];
- //sound siren
- _pos = position _target;
- diag_log format ["AIRRAID: POS: %1 | TARGET: %2 | SHOULD MATCH",_pos,_targetpos];
- _siren = createVehicle ["HeliHEmpty",position _target,[], 0, "NONE"];
- [nil,_siren,rSAY,['eve', 3500]] call RE;
- sleep 60;
- _pos1 = position _siren;
- diag_log format ["AIRRAID: SIREN: %1 | TARGET: %2 | SHOULD MATCH APPROX",_pos1,_targetpos];
- [nil,_siren,rSAY,['puk', 3500]] call RE;
- sleep 60;
- [nil,_siren,rSAY,['eve', 3500]] call RE;
- sleep 60;
- [nil,_siren,rSAY,['nam', 3500]] call RE;
- sleep 10;
- [nil,_siren,rSAY,['puk', 3500]] call RE;
- sleep 60;
- [nil,_siren,rSAY,['nam', 3500]] call RE;
- sleep 5;
- //start bombing init
- _choise = _choice; // choise bombing: 1 = light 2 = medium 3 = heavy
- //_ray = 120;
- _seconds = _duration; // time bombing
- _dblsecs = _seconds * 2;
- diag_log format ["AIRRAID: Bombing Area: %1 %2",_xpos,_ypos];
- //start bombing
- _pos2 = [getPosATL _siren];
- While {_seconds > 1} do {
- _sound = createVehicle ["HeliHEmpty",position _target,[], _ray, "NONE"];
- [nil,_sound,rSAY,['mortar1', 3500]] call RE;
- _pos2 set [_seconds, getPosATL _sound];
- sleep 2;
- If (_choise == 1) then {
- _espl = createVehicle ["SH_105_HE",position _sound,[], 0, "NONE"];
- };
- If (_choise == 2) then {
- _espl = createVehicle ["SH_125_HE",position _sound,[], 0, "NONE"];
- };
- If (_choise == 3) then {
- _espl = createVehicle ["BO_GBU12_LGB",position _sound,[], 0, "NONE"];
- };
- _pos2 = [_dblsecs,getPosATL _espl];
- _pos2cnt = count _pos2;
- diag_log format ["AIRRAID: BOMB: %1 | TARGET: %2 | SHOULD MATCH APPROX ||| debug arraycount %3 |",str(_pos2),_targetpos,_pos2cnt];
- _seconds = _seconds - 1;
- deletevehicle _sound;
- };
- //cleanup
- sleep 60;
- _repeat = _repeat - 1;
- deletevehicle _espl;
- deletevehicle _siren;
- deletevehicle _loc;
- deletevehicle _target;
- diag_log format ["AIRRAID: Going down for sleep: Repeat:%1 | Sleep:%2",_repeat,_break];
- sleep _break;
- };
- exit
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement