Guest User

Untitled

a guest
Nov 27th, 2015
72
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Private ["_minimumAnamalii","_maxsimumAnamalii","_markeriNaKarte","_max_artifactov","_art_chance","_anamalyArray","_max_art","_min_anamalies","_max_anamalies","_kolichestvo_anamalies","_b","_rnd","_rnd_count","_ms","_ms_2","_anamalyArraySelected","_pos","_a","_kolichestvo_art","_anamaliya_name","_anamaliya","_marker_name","_marker","_anamalyArraySelected4","_countArtifactov","_art","_pos_art","_art_spawn","_razmer_ms"];
  2.  
  3. diag_log "[Randomnaya_Generaciya_Anamalii]: skript zagrujen";
  4.  
  5. _minimumAnamalii = 25;
  6. _maxsimumAnamalii = 50;
  7. _markeriNaKarte = true;
  8. _max_artifactov = 3;
  9. _art_chance = 50;
  10. _anamalyArray = [
  11. [
  12. "Burn",
  13. 20,
  14. [20, 20, 0, false],
  15. ["this", "XC=[thistrigger,10]execvm ""anamalies\Burn.sqf"";", ""],
  16. ["DAP_TEARS","DAP_FIRE"]
  17. ],
  18. [
  19. "Gravi",
  20. 20,
  21. [20, 20, 0, false],
  22. ["this", "XC=[thistrigger,10]execvm ""anamalies\Gravi.sqf"";", ""],
  23. ["DAP_BLACKDRIP","DAP_GRAVI","DAP_EMPTY"]
  24. ],
  25. [
  26. "Trampoline",
  27. 20,
  28. [20, 20, 0, false],
  29. ["this", "XC=[thistrigger,10]execvm ""anamalies\Trampoline.sqf"";", ""],
  30. ["DAP_BLACKDRIP","DAP_GRAVI","DAP_EMPTY"]
  31. ],
  32. [
  33. "Mincer",
  34. 20,
  35. [20, 20, 0, false],
  36. ["this", "XC=[thistrigger,10]execvm ""anamalies\Mincer.sqf"";", ""],
  37. ["DAP_STONEBLOOD","DAP_MEAT","DAP_SOUL"]
  38. ],
  39. [
  40. "Electro",
  41. 30,
  42. [30, 30, 0, false],
  43. ["this", "XC=[thistrigger,15]execvm ""anamalies\Electro.sqf"";", ""],
  44. ["DAP_ELECTRA","DAP_SPIKES","DAP_BATTERY"]
  45. ],
  46. [
  47. "Galantine",
  48. 50,
  49. [50, 50, 0, false],
  50. ["this", "XC=[thistrigger,50]execvm ""anamalies\Galantine.sqf"";", ""],
  51. ["DAP_AMEBA","DAP_CRYSTALL"]
  52. ],
  53. [
  54. "Radiation",
  55. 100,
  56. [100, 100, 0, false],
  57. ["this", "XC=[thistrigger,100]execvm ""anamalies\Radiation.sqf"";", ""],
  58. []
  59. ],
  60. [
  61. "Psy",
  62. 250,
  63. [250, 250, 0, false],
  64. ["this", "XC=[thistrigger,250]execvm ""anamalies\Psy.sqf"";", ""],
  65. []
  66. ]
  67. ];
  68.  
  69. waitUntil {(!isNil "BIS_fnc_selectRandom")};
  70. waitUntil {(!isNil "BIS_fnc_findSafePos")};
  71.  
  72. _max_art = _max_artifactov + 1;
  73. _min_anamalies = _minimumAnamalii - 1;
  74. _max_anamalies = _maxsimumAnamalii - _minimumAnamalii;
  75. _kolichestvo_anamalies = floor (random _max_anamalies) + _min_anamalies;
  76. _b = 0;
  77. _rnd = 0;
  78. _rnd_count = count _anamalyArray;
  79. _ms = [];
  80. _ms_2 = [];
  81.  
  82. diag_log format["[Randomnaya_Generaciya_Anamalii]: vsego_anamalii (%1)",_kolichestvo_anamalies];
  83.  
  84. While {_b < _kolichestvo_anamalies} do {
  85. _rnd = floor (random _rnd_count);
  86. _anamalyArraySelected = (_anamalyArray select _rnd);
  87. _b = _b + 1;
  88. _pos = [getMarkerPos 'Center',0,dayz_MapArea,25,0,2000,0] call BIS_fnc_findSafePos;
  89. _a = 0;
  90. _kolichestvo_art = floor (random _max_art);
  91. _anamaliya_name = (_anamalyArraySelected select 0);
  92. _anamaliya = createTrigger ["EmptyDetector", _pos];
  93. _anamaliya setTriggerArea (_anamalyArraySelected select 2);
  94. _anamaliya setTriggerActivation ["ANY", "PRESENT", true];
  95. _anamaliya setTriggerStatements (_anamalyArraySelected select 3);
  96. _marker_name = str _b;
  97. if (_markeriNaKarte) then {
  98. _marker = createMarker [_marker_name, _pos];
  99. _marker setMarkerShape "ICON";
  100. _marker setMarkerType "DOT";
  101. _marker setMarkerText _anamaliya_name;
  102. };
  103. _anamalyArraySelected4 = _anamalyArraySelected select 4;
  104. _countArtifactov = count _anamalyArraySelected4;
  105. if (_countArtifactov == 0) then {
  106. _ms = [];
  107. _ms_2 = [];
  108. } else {
  109. While {_a < _kolichestvo_art} do {
  110. if ((floor (random 100) < _art_chance)) then {
  111. _art = _anamalyArraySelected4 call BIS_fnc_selectRandom;
  112. _pos_art = [_pos, 1, (_anamalyArraySelected select 1), 3, 0, 20, 0] call BIS_fnc_findSafePos;
  113. _art_spawn = _art createVehicle _pos_art;
  114. _ms set [_a, _art];
  115. _ms_2 set [_a, _pos_art];
  116. };
  117. _a = _a + 1;
  118. };
  119. };
  120. _razmer_ms = count _ms;
  121.  
  122. diag_log format["[Randomnaya_Generaciya_Anamalii]: Nazvanie_Anamalii: %1 Koordinati_Anamalii: %2 Vsego_Artifactov: %3 Artefacti: %4 Koordinati_Artefactov: %5",_anamaliya_name,_pos,_razmer_ms,_ms,_ms_2];
  123.  
  124. };
  125.  
  126. diag_log "[Randomnaya_Generaciya_Anamalii]: skript vipolnen";
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×