Advertisement
meanbeandk

variables.sqf

Oct 2nd, 2014
196
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 25.25 KB | None | 0 0
  1. disableSerialization;
  2.  
  3. //Model Variables
  4. Bandit1_DZ = "Bandit1_DZ";
  5. Bandit2_DZ = "Bandit2_DZ";
  6. BanditW1_DZ = "BanditW1_DZ";
  7. BanditW2_DZ = "BanditW2_DZ";
  8. Survivor1_DZ = "Survivor2_DZ";
  9. Survivor2_DZ = "Survivor2_DZ";
  10. SurvivorW2_DZ = "SurvivorW2_DZ";
  11. SurvivorW3_DZ = "SurvivorW2_DZ";
  12. Sniper1_DZ = "Sniper1_DZ";
  13. Camo1_DZ = "Camo1_DZ";
  14. Soldier1_DZ = "Soldier1_DZ";
  15. Rocket_DZ = "Rocket_DZ";
  16.  
  17. AllPlayers = ["Survivor2_DZ","SurvivorWcombat_DZ","SurvivorWdesert_DZ","SurvivorWurban_DZ","SurvivorWsequishaD_DZ","SurvivorWsequisha_DZ","SurvivorWpink_DZ","SurvivorW3_DZ","SurvivorW2_DZ","Bandit1_DZ","Bandit2_DZ","BanditW1_DZ","BanditW2_DZ","Soldier_Crew_PMC","Sniper1_DZ","Camo1_DZ","Soldier1_DZ","Rocket_DZ","Rocker1_DZ","Rocker2_DZ","Rocker3_DZ","Rocker4_DZ","Priest_DZ","Functionary1_EP1_DZ","GUE_Commander_DZ","Ins_Soldier_GL_DZ","Haris_Press_EP1_DZ","Pilot_EP1_DZ","RU_Policeman_DZ","pz_policeman","pz_suit1","pz_suit2","pz_worker1","pz_worker2","pz_worker3","pz_doctor","pz_teacher","pz_hunter","pz_villager1","pz_villager2","pz_villager3","pz_priest","Soldier_TL_PMC_DZ","Soldier_Sniper_PMC_DZ","Soldier_Bodyguard_AA12_PMC_DZ","Drake_Light_DZ","CZ_Special_Forces_GL_DES_EP1_DZ","TK_INS_Soldier_EP1_DZ","TK_INS_Warlord_EP1_DZ","FR_OHara_DZ","FR_Rodriguez_DZ","CZ_Soldier_Sniper_EP1_DZ","Graves_Light_DZ","GUE_Soldier_MG_DZ","GUE_Soldier_Sniper_DZ","GUE_Soldier_Crew_DZ","GUE_Soldier_CO_DZ","GUE_Soldier_2_DZ","TK_Special_Forces_MG_EP1_DZ","TK_Soldier_Sniper_EP1_DZ","TK_Commander_EP1_DZ","RU_Soldier_Crew_DZ","INS_Lopotev_DZ","INS_Soldier_AR_DZ","INS_Soldier_CO_DZ","INS_Bardak_DZ","INS_Worker2_DZ"];
  18. MeleeWeapons = ["MeleeFishingPole","MeleeCrowbar","MeleeBaseBallBatNails","MeleeBaseBallBatBarbed","MeleeBaseBallBat","Crossbow_DZ","MeleeSledge","MeleeMachete","MeleeHatchet_DZE"];
  19. gear_done = false;
  20. //Cooking
  21. meatraw = [
  22. "FoodSteakRaw",
  23. "FoodmeatRaw",
  24. "FoodbeefRaw",
  25. "FoodmuttonRaw",
  26. "FoodchickenRaw",
  27. "FoodrabbitRaw",
  28. "FoodbaconRaw",
  29. "ItemTrout",
  30. "ItemSeaBass",
  31. "ItemTuna"
  32. ];
  33. exceptionsraw = ["ItemTuna"];
  34. meatcooked = [
  35. "FoodSteakCooked",
  36. "FoodmeatCooked",
  37. "FoodbeefCooked",
  38. "FoodmuttonCooked",
  39. "FoodchickenCooked",
  40. "FoodrabbitCooked",
  41. "FoodbaconCooked",
  42. "ItemTroutCooked",
  43. "ItemSeaBassCooked",
  44. "ItemTunaCooked"
  45. ];
  46. //Eating
  47. no_output_food = ["FoodMRE", "FoodPistachio", "FoodNutmix","FoodBioMeat"]+meatcooked+meatraw;
  48.  
  49. // Food with increased chance for infection.
  50. badfood = ["FoodBioMeat","FoodCanUnlabeled"];
  51.  
  52. food_with_output=[
  53. "FoodCanBakedBeans",
  54. "FoodCanSardines",
  55. "FoodCanFrankBeans",
  56. "FoodCanPasta",
  57. "FoodCanGriff",
  58. "FoodCanBadguy",
  59. "FoodCanBoneboy",
  60. "FoodCanCorn",
  61. "FoodCanCurgon",
  62. "FoodCanDemon",
  63. "FoodCanFraggleos",
  64. "FoodCanHerpy",
  65. "FoodCanOrlok",
  66. "FoodCanPowell",
  67. "FoodCanTylers",
  68. "FoodCanUnlabeled"
  69. ];
  70.  
  71. food_output = [
  72. "TrashTinCan",
  73. "TrashTinCan",
  74. "TrashTinCan",
  75. "TrashTinCan",
  76. "FoodCanGriffEmpty",
  77. "FoodCanBadguyEmpty",
  78. "FoodCanBoneboyEmpty",
  79. "FoodCanCornEmpty",
  80. "FoodCanCurgonEmpty",
  81. "FoodCanDemonEmpty",
  82. "FoodCanFraggleosEmpty",
  83. "FoodCanHerpyEmpty",
  84. "FoodCanOrlokEmpty",
  85. "FoodCanPowellEmpty",
  86. "FoodCanTylersEmpty",
  87. "FoodCanUnlabeledEmpty"
  88. ];
  89. //Drinking
  90. no_output_drink = ["ItemWaterbottle", "ItemWaterbottleBoiled"];
  91. drink_with_output = [
  92. "ItemSoda", //just to define item for ItemSodaEmpty
  93. "ItemSodaRbull",
  94. "ItemSodaOrangeSherbet",
  95. "ItemSodaCoke",
  96. "ItemSodaPepsi",
  97. "ItemSodaMdew",
  98. "ItemSodaMtngreen",
  99. "ItemSodaR4z0r",
  100. "ItemSodaClays",
  101. "ItemSodaSmasht",
  102. "ItemSodaDrwaste",
  103. "ItemSodaLemonade",
  104. "ItemSodaLvg",
  105. "ItemSodaMzly",
  106. "ItemSodaRabbit"
  107. ];
  108. drink_output = [
  109. "ItemSodaEmpty",
  110. "ItemSodaEmpty",
  111. "ItemSodaEmpty",
  112. "ItemSodaCokeEmpty",
  113. "ItemSodaPepsiEmpty",
  114. "ItemSodaMdewEmpty",
  115. "ItemSodaMtngreenEmpty",
  116. "ItemSodaR4z0rEmpty",
  117. "ItemSodaClaysEmpty",
  118. "ItemSodaSmashtEmpty",
  119. "ItemSodaDrwasteEmpty",
  120. "ItemSodaLemonadeEmpty",
  121. "ItemSodaLvgEmpty",
  122. "ItemSodaMzlyEmpty",
  123. "ItemSodaRabbitEmpty"
  124. ];
  125. boil_tin_cans = [
  126. "TrashTinCan",
  127. "FoodCanGriffEmpty",
  128. "FoodCanBadguyEmpty",
  129. "FoodCanBoneboyEmpty",
  130. "FoodCanCornEmpty",
  131. "FoodCanCurgonEmpty",
  132. "FoodCanDemonEmpty",
  133. "FoodCanFraggleosEmpty",
  134. "FoodCanHerpyEmpty",
  135. "FoodCanOrlokEmpty",
  136. "FoodCanPowellEmpty",
  137. "FoodCanTylersEmpty",
  138. "FoodCanUnlabeledEmpty",
  139. "ItemSodaEmpty",
  140. "ItemSodaCokeEmpty",
  141. "ItemSodaPepsiEmpty",
  142. "ItemSodaMdewEmpty",
  143. "ItemSodaMtngreenEmpty",
  144. "ItemSodaR4z0rEmpty",
  145. "ItemSodaClaysEmpty",
  146. "ItemSodaSmashtEmpty",
  147. "ItemSodaDrwasteEmpty",
  148. "ItemSodaLemonadeEmpty",
  149. "ItemSodaLvgEmpty",
  150. "ItemSodaMzlyEmpty",
  151. "ItemSodaRabbitEmpty"
  152. ];
  153.  
  154. dayz_combination = "";
  155. dayz_humanitytarget = "";
  156. dayz_combatLog = "";
  157. canRoll = true;
  158.  
  159. canbuild = true;
  160.  
  161. //Hunting Variables
  162. dayZ_partClasses = [
  163. "PartFueltank",
  164. "PartWheel",
  165. //"PartGeneric", //No need to add, it is default for everything
  166. "PartEngine"
  167. ];
  168. dayZ_explosiveParts = [
  169. "palivo",
  170. "motor"
  171. ];
  172. //Survival Variables
  173. SleepFood = 2160; //minutes (48 hours)
  174. SleepWater = 1440; //minutes (24 hours)
  175. SleepTemperatur = 90 / 100; //Firs Value = Minutes untill Player reaches the coldest Point at night (without other effects! night factor expected to be -1) //TeeChange
  176.  
  177. //Server Variables
  178. allowConnection = false;
  179. isSinglePlayer = false;
  180. PVDZE_serverObjectMonitor = [];
  181. PlayerDeaths = [];
  182.  
  183. //Streaming Variables (player only)
  184. dayz_Locations = [];
  185. dayz_locationsActive = [];
  186.  
  187. //GUI
  188. Dayz_GUI_R = 0.38; // 0.7
  189. Dayz_GUI_G = 0.63; // -0.63
  190. Dayz_GUI_B = 0.26; // -0.26
  191.  
  192. //Player self-action handles
  193. dayz_resetSelfActions = {
  194. s_player_fire = -1;
  195. s_player_cook = -1;
  196. s_player_boil = -1;
  197. s_player_fireout = -1;
  198. s_player_butcher = -1;
  199. s_player_packtent = -1;
  200. s_player_packvault = -1;
  201. s_player_lockvault = -1;
  202. s_player_unlockvault = -1;
  203. s_player_fillwater = -1;
  204. s_player_fillwater2 = -1;
  205. s_player_fillfuel = -1;
  206. s_player_grabflare = -1;
  207. s_player_callzombies = -1;
  208. s_player_showname = -1;
  209. s_player_debuglootpos = -1;
  210. s_player_pzombiesattack = -1;
  211. s_player_pzombiesvision = -1;
  212. s_player_pzombiesfeed = -1;
  213. s_player_removeflare = -1;
  214. s_player_painkiller = -1;
  215. s_player_studybody = -1;
  216. s_player_tamedog = -1;
  217. s_player_madsci_crtl = -1;
  218. s_player_parts_crtl = -1;
  219. s_build_Sandbag1_DZ = -1;
  220. s_build_Hedgehog_DZ = -1;
  221. s_build_Wire_cat1 = -1;
  222. s_player_deleteBuild = -1;
  223. s_player_forceSave = -1;
  224. s_player_checkGear = -1;
  225. s_player_flipveh = -1;
  226. s_player_stats = -1;
  227. s_player_sleep = -1;
  228. s_player_movedog = -1;
  229. s_player_speeddog = -1;
  230. s_player_calldog = -1;
  231. s_player_feeddog = -1;
  232. s_player_waterdog = -1;
  233. s_player_staydog = -1;
  234. s_player_trackdog = -1;
  235. s_player_barkdog = -1;
  236. s_player_warndog = -1;
  237. s_player_followdog = -1;
  238. s_player_repair_crtl = -1;
  239. s_player_information = -1;
  240. s_player_fuelauto = -1;
  241. s_player_fuelauto2 = -1;
  242. s_player_fillgen = -1;
  243. s_player_upgrade_build = -1;
  244. s_player_maint_build = -1;
  245. s_player_downgrade_build = -1;
  246. s_player_towing = -1;
  247. s_halo_action = -1;
  248. s_player_SurrenderedGear = -1;
  249. s_player_maintain_area = -1;
  250. s_player_maintain_area_preview = -1;
  251. s_player_heli_lift = -1;
  252. s_player_heli_detach = -1;
  253. s_player_lockUnlock_crtl = -1;
  254. };
  255. call dayz_resetSelfActions;
  256.  
  257. //Engineering variables
  258. s_player_lastTarget = [objNull,objNull,objNull,objNull,objNull];
  259. s_player_repairActions = [];
  260. s_player_lockunlock = [];
  261.  
  262. // Custom
  263. s_player_madsci = [];
  264. s_player_parts = [];
  265. s_player_combi = [];
  266.  
  267. //Initialize Medical Variables
  268. r_interrupt = false;
  269. r_doLoop = false;
  270. r_self = false;
  271. r_self_actions = [];
  272. r_drag_sqf = false;
  273. r_action = false;
  274. r_action_unload = false;
  275. r_player_handler = false;
  276. r_player_handler1 = false;
  277. r_player_dead = false;
  278. r_player_unconscious = false;
  279. r_player_infected = false;
  280. r_player_injured = false;
  281. r_player_inpain = false;
  282. r_player_loaded = false;
  283. r_player_cardiac = false;
  284. r_fracture_legs = false;
  285. r_fracture_arms = false;
  286. r_player_vehicle = player;
  287. r_player_blood = 12000;
  288. r_player_lowblood = false;
  289. r_player_timeout = 0;
  290. r_player_bloodTotal = r_player_blood;
  291. r_public_blood = r_player_blood;
  292. r_player_bloodDanger = r_player_bloodTotal * 0.2;
  293. r_player_actions = [];
  294. r_handlerCount = 0;
  295. r_action_repair = false;
  296. r_action_targets = [];
  297. r_pitchWhine = false;
  298. r_isBandit = false;
  299. isInTraderCity = false;
  300. NORRN_dropAction = -1;
  301. DZE_PROTOBOX = objNull;
  302.  
  303. //ammo routine
  304. r_player_actions2 = [];
  305. r_action2 = false;
  306. r_player_lastVehicle = objNull;
  307. r_player_lastSeat = [];
  308. r_player_removeActions2 = {
  309. if (!isNull r_player_lastVehicle) then {
  310. {
  311. r_player_lastVehicle removeAction _x;
  312. } count r_player_actions2;
  313. r_player_actions2 = [];
  314. r_action2 = false;
  315. };
  316. };
  317.  
  318. USEC_woundHit = [
  319. "",
  320. "body",
  321. "hands",
  322. "legs",
  323. "head_hit"
  324. ];
  325. DAYZ_woundHit = [
  326. [
  327. "body",
  328. "hands",
  329. "legs",
  330. "head_hit"
  331. ],
  332. [ 0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,2,2,3]
  333. ];
  334. DAYZ_woundHit_ok = [
  335. [
  336. "body",
  337. "hands",
  338. "legs"
  339. ],
  340. [0,0,0,0,0,1,1,1,2,2]
  341. ];
  342. DAYZ_woundHit_dog = [
  343. [
  344. "body",
  345. "hands",
  346. "legs"
  347. ],
  348. [0,0,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2]
  349. ];
  350. USEC_MinorWounds = [
  351. "hands",
  352. "legs"
  353. ];
  354. USEC_woundPoint = [
  355. ["Pelvis","aimpoint"],
  356. ["aimpoint"], //,"RightShoulder","LeftShoulder"
  357. ["lelbow","relbow"],
  358. ["RightFoot","LeftFoot"],
  359. ["neck","pilot"]
  360. ];
  361. USEC_typeOfWounds = [
  362. "Pelvis",
  363. "aimpoint",
  364. "lelbow","relbow",
  365. "RightFoot","LeftFoot",
  366. "neck","pilot"
  367. ];
  368.  
  369. DZE_vehicleZwounds = [
  370. "sklo predni L",
  371. "sklo predni P",
  372. "sklo zadni",
  373. "sklo zadni L",
  374. "sklo zadni P",
  375. "sklo P",
  376. "Glass1",
  377. "Glass2",
  378. "Glass3",
  379. "Glass4",
  380. "Glass5",
  381. "Glass6"
  382. ];
  383.  
  384. DZE_HeliAllowTowFrom = [
  385. "CH_47F_EP1_DZE",
  386. "CH_47F_EP1_DZ",
  387. "CH_47F_BAF",
  388. "CH_47F_EP1",
  389. "BAF_Merlin_DZE",
  390. "CH53_DZE"
  391. ];
  392.  
  393. DZE_HeliAllowToTow = [
  394. "hilux1_civil_1_open",
  395. "HMMWV_Base",
  396. "Lada_base",
  397. "Offroad_DSHKM_base",
  398. "Pickup_PK_base",
  399. "SkodaBase",
  400. "tractor",
  401. "VWGolf",
  402. "Volha_TK_CIV_Base_EP1",
  403. "S1203_TK_CIV_EP1",
  404. "SUV_Base_EP1",
  405. "ArmoredSUV_Base_PMC",
  406. "UAZ_Base",
  407. "LandRover_Base",
  408. "Ship"
  409. ];
  410.  
  411. //Initialize Zombie Variables
  412. dayz_zombieTargetList = [
  413. ["SoldierWB",50],
  414. ["Air",500],
  415. ["LandVehicle",200]
  416. ];
  417. PVDZE_plr_Hit = [];
  418. PVDZE_obj_Publish = []; //used for eventhandler to spawn a mirror of players tent
  419. PVDZE_plr_HideBody = objNull;
  420. dayz_selectedVault = objNull;
  421. dayz_selectedDoor = objNull;
  422.  
  423. PVDZE_veh_Publish = []; // for vehicle traders
  424. PVDZE_obj_Trade = []; // For all traders increment qty
  425. PVDZE_plr_TradeMenu = []; // For all traders
  426. PVDZE_plr_DeathB = [];
  427.  
  428. //DayZ settings
  429. dayz_dawn = 6;
  430. dayz_dusk = 18;
  431. DAYZ_agentnumber = 0;
  432. dayz_animalDistance = 800;
  433. dayz_zSpawnDistance = 1000;
  434.  
  435. dayz_maxMaxModels = 80; // max quantity of Man models (player || Z, dead || alive) around players. Below this limit we can spawn Z // max quantity of loot piles around players. Below this limit we can spawn some loot
  436. dayz_spawnArea = 200; // radius around player where we can spawn loot & Z
  437. dayz_cantseeDist = 150; // distance from which we can spawn a Z in front of any player without ray-tracing && angle checks
  438. dayz_cantseefov = 70; // half player field-of-view. Visible Z won't be spawned in front of any near players
  439. dayz_canDelete = 300; // Z, further than this distance from its "owner", will be deleted
  440.  
  441. if(isNil "DZE_SelfTransfuse") then {
  442. DZE_SelfTransfuse = false;
  443. };
  444. if(isNil "dayz_maxAnimals") then {
  445. dayz_maxAnimals = 5;
  446. };
  447. if(isNil "timezoneswitch") then {
  448. timezoneswitch = 0;
  449. };
  450. if(isNil "dayz_maxLocalZombies") then {
  451. dayz_maxLocalZombies = 15;
  452. };
  453. if(isNil "dayz_maxGlobalZombiesInit") then {
  454. dayz_maxGlobalZombiesInit = 15;
  455. };
  456. if(isNil "dayz_maxGlobalZombiesIncrease") then {
  457. dayz_maxGlobalZombiesIncrease = 5;
  458. };
  459. if(isNil "dayz_maxZeds") then {
  460. dayz_maxZeds = 500;
  461. };
  462. if (isNil "DZE_PlayerZed") then {
  463. DZE_PlayerZed = true;
  464. };
  465. if (isNil "DZE_GodModeBase") then {
  466. DZE_GodModeBase = false;
  467. };
  468. if(isNil "DZEdebug") then {
  469. DZEdebug = false;
  470. };
  471. if (isNil "DZE_Debug_Damage") then {
  472. DZE_Debug_Damage = true;
  473. };
  474. if(isNil "DZE_TRADER_SPAWNMODE") then {
  475. DZE_TRADER_SPAWNMODE = false;
  476. };
  477. if(isNil "dayz_tameDogs") then {
  478. dayz_tameDogs = false;
  479. };
  480. if(isNil "dayz_sellDistance_vehicle") then {
  481. dayz_sellDistance_vehicle = 10;
  482. };
  483. if(isNil "dayz_sellDistance_boat") then {
  484. dayz_sellDistance_boat = 30;
  485. };
  486. if(isNil "dayz_sellDistance_air") then {
  487. dayz_sellDistance_air = 40;
  488. };
  489. if(isNil "dayz_paraSpawn") then {
  490. dayz_paraSpawn = false;
  491. };
  492. if(isNil "dayz_minpos") then {
  493. dayz_minpos = -20000;
  494. };
  495. if(isNil "dayz_maxpos") then {
  496. dayz_maxpos = 20000;
  497. };
  498. if(isNil "DZE_BuildingLimit") then {
  499. DZE_BuildingLimit = 150;
  500. };
  501. if(isNil "DZE_HumanityTargetDistance") then {
  502. DZE_HumanityTargetDistance = 25;
  503. };
  504. if(isNil "DZE_FriendlySaving") then {
  505. DZE_FriendlySaving = true;
  506. };
  507. if(isNil "DZE_BuildOnRoads") then {
  508. DZE_BuildOnRoads = false;
  509. };
  510. if(isNil "DZE_MissionLootTable") then {
  511. DZE_MissionLootTable = false;
  512. };
  513. if(isNil "DZE_ConfigTrader") then {
  514. DZE_ConfigTrader = false;
  515. };
  516. if(isNil "DZE_LootSpawnTimer") then {
  517. DZE_LootSpawnTimer = 10;
  518. };
  519. if(isNil "DZE_HeliLift") then {
  520. DZE_HeliLift = true;
  521. };
  522. if(isNil "DZE_DamageBeforeMaint") then {
  523. DZE_DamageBeforeMaint = 0.09;
  524. };
  525. if(isNil "DZE_StaticConstructionCount") then {
  526. DZE_StaticConstructionCount = 0;
  527. };
  528. if (isNil "DZE_selfTransfuse_Values") then {
  529. DZE_selfTransfuse_Values = [12000, 15, 300];
  530. };
  531.  
  532. // needed on server
  533. if(isNil "DZE_PlotPole") then {
  534. DZE_PlotPole = [30,45];
  535. };
  536. if(isNil "DZE_maintainRange") then {
  537. DZE_maintainRange = ((DZE_PlotPole select 0)+20);
  538. };
  539.  
  540. DZE_REPLACE_WEAPONS = [["Crossbow","ItemMatchbox","ItemHatchet"],["Crossbow_DZ","ItemMatchbox_DZE","ItemHatchet_DZE"]];
  541.  
  542. if(isNil "dayz_zedSpawnVehCount") then {
  543. dayz_zedSpawnVehCount = dayz_maxLocalZombies / 2;
  544. };
  545. if(isNil "dayz_spawnAirCount") then {
  546. dayz_spawnAirCount = 0;
  547. };
  548. if(isNil "dayz_zedsAttackVehicles") then {
  549. dayz_zedsAttackVehicles = true;
  550. };
  551.  
  552. // update objects
  553. dayz_updateObjects = ["Plane","Tank","Car", "Helicopter", "Motorcycle", "Ship", "TentStorage", "VaultStorage","LockboxStorage","OutHouse_DZ","Wooden_shed_DZ","WoodShack_DZ","StorageShed_DZ","GunRack_DZ","WoodCrate_DZ","Scaffolding_DZ"];
  554. dayz_disallowedVault = ["TentStorage", "BuiltItems","ModularItems","DZE_Base_Object"];
  555. dayz_reveal = ["AllVehicles","WeaponHolder","Land_A_tent","BuiltItems","ModularItems","DZE_Base_Object"];
  556. dayz_allowedObjects = ["TentStorage","MetalFloor_Preview_DZ","TentStorageDomed","TentStorageDomed2", "VaultStorageLocked", "Hedgehog_DZ", "Sandbag1_DZ","BagFenceRound_DZ","TrapBear","Fort_RazorWire","WoodGate_DZ","Land_HBarrier1_DZ","Land_HBarrier3_DZ","Land_HBarrier5_DZ","Fence_corrugated_DZ","M240Nest_DZ","CanvasHut_DZ","ParkBench_DZ","MetalGate_DZ","OutHouse_DZ","Wooden_shed_DZ","WoodShack_DZ","StorageShed_DZ","Plastic_Pole_EP1_DZ","Generator_DZ","StickFence_DZ","LightPole_DZ","FuelPump_DZ","DesertCamoNet_DZ","ForestCamoNet_DZ","DesertLargeCamoNet_DZ","ForestLargeCamoNet_DZ","SandNest_DZ","DeerStand_DZ","MetalPanel_DZ","WorkBench_DZ","WoodFloor_DZ","WoodLargeWall_DZ","WoodLargeWallDoor_DZ","WoodLargeWallWin_DZ","WoodSmallWall_DZ","WoodSmallWallWin_DZ","WoodSmallWallDoor_DZ","LockboxStorageLocked","WoodFloorHalf_DZ","WoodFloorQuarter_DZ","WoodStairs_DZ","WoodStairsSans_DZ","WoodStairsRails_DZ","WoodSmallWallThird_DZ","WoodLadder_DZ","Land_DZE_GarageWoodDoor","Land_DZE_LargeWoodDoor","Land_DZE_WoodDoor","Land_DZE_GarageWoodDoorLocked","Land_DZE_LargeWoodDoorLocked","Land_DZE_WoodDoorLocked","CinderWallHalf_DZ","CinderWall_DZ","CinderWallDoorway_DZ","CinderWallDoor_DZ","CinderWallDoorLocked_DZ","CinderWallSmallDoorway_DZ","CinderWallDoorSmall_DZ","CinderWallDoorSmallLocked_DZ","MetalFloor_DZ","WoodRamp_DZ","GunRack_DZ","FireBarrel_DZ","WoodCrate_DZ","Scaffolding_DZ"];
  557.  
  558. DZE_LockableStorage = ["VaultStorage","VaultStorageLocked","LockboxStorageLocked","LockboxStorage"];
  559. DZE_LockedStorage = ["VaultStorageLocked","LockboxStorageLocked"];
  560. DZE_UnLockedStorage = ["VaultStorage","LockboxStorage"];
  561. DZE_maintainClasses = ["ModularItems","DZE_Housebase","LightPole_DZ","BuiltItems","Plastic_Pole_EP1_DZ","Fence_corrugated_DZ","CanvasHut_DZ","ParkBench_DZ","MetalGate_DZ","StickFence_DZ","DesertCamoNet_DZ","ForestCamoNet_DZ","DesertLargeCamoNet_DZ","ForestLargeCamoNet_DZ","DeerStand_DZ","Scaffolding_DZ","FireBarrel_DZ"];
  562.  
  563. DZE_DoorsLocked = ["Land_DZE_GarageWoodDoorLocked","Land_DZE_LargeWoodDoorLocked","Land_DZE_WoodDoorLocked","CinderWallDoorLocked_DZ","CinderWallDoorSmallLocked_DZ"];
  564.  
  565. // List of removable items that require crowbar
  566. DZE_isRemovable = ["Fence_corrugated_DZ","M240Nest_DZ","ParkBench_DZ","Plastic_Pole_EP1_DZ","FireBarrel_DZ","Scaffolding_DZ"];
  567. DZE_isWreck = ["SKODAWreck","HMMWVWreck","UralWreck","datsun01Wreck","hiluxWreck","datsun02Wreck","UAZWreck","Land_Misc_Garb_Heap_EP1","Fort_Barricade_EP1","Rubbish2"];
  568. DZE_isWreckBuilding = ["Land_wreck_cinder","Land_wood_wreck_quarter","Land_wood_wreck_floor","Land_wood_wreck_third","Land_wood_wreck_frame","Land_iron_vein_wreck","Land_silver_vein_wreck","Land_gold_vein_wreck","Land_ammo_supply_wreck"];
  569. DZE_isNewStorage = ["VaultStorage","OutHouse_DZ","Wooden_shed_DZ","WoodShack_DZ","StorageShed_DZ","GunRack_DZ","WoodCrate_DZ"];
  570.  
  571. // These work with just a running generator
  572. dayz_fuelpumparray = ["FuelPump_DZ","Land_A_FuelStation_Feed","Land_Ind_FuelStation_Feed_EP1","Land_FuelStation_Feed_PMC","FuelStation","Land_ibr_FuelStation_Feed","Land_fuelstation_army","Land_fuelstation","land_fuelstation_w","Land_benzina_schnell"];
  573. DZE_fueltruckarray = ["KamazRefuel_DZ","UralRefuel_TK_EP1_DZ","MtvrRefuel_DES_EP1_DZ","V3S_Refuel_TK_GUE_EP1_DZ","MtvrRefuel_DZ","KamazRefuel_DZE","UralRefuel_TK_EP1_DZE","MtvrRefuel_DES_EP1_DZE","V3S_Refuel_TK_GUE_EP1_DZE","MtvrRefuel_DZE"];
  574.  
  575. // Standard Fuel sources
  576. dayz_fuelsources = ["Land_Ind_TankSmall","Land_fuel_tank_big","Land_fuel_tank_stairs","Land_fuel_tank_stairs_ep1","Land_wagon_tanker","Land_fuelstation","Land_fuelstation_army","land_fuelstation_w","Land_benzina_schnell"];
  577.  
  578. DZE_Lock_Door = "";
  579.  
  580. //init global arrays for Loot Chances
  581. call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\loot_init.sqf";
  582.  
  583. if(isServer) then {
  584. dayz_players = [];
  585. dead_bodyCleanup = [];
  586. needUpdate_objects = [];
  587.  
  588. DZE_DYN_AntiStuck = 0;
  589. DZE_DYN_AntiStuck2nd = 0;
  590. DZE_DYN_AntiStuck3rd = 0;
  591.  
  592. if(isNil "dayz_fullMoonNights") then {
  593. dayz_fullMoonNights = false;
  594. };
  595. if(isNil "EpochEvents") then {
  596. EpochEvents = [];
  597. };
  598. if(isNil "DZE_vehicleAmmo") then {
  599. DZE_vehicleAmmo = 0;
  600. };
  601.  
  602. if(isNil "DZE_BackpackGuard") then {
  603. DZE_BackpackGuard = true;
  604. };
  605.  
  606. if(isNil "DZE_CleanNull") then {
  607. DZE_CleanNull = false;
  608. };
  609. if (isNil "DZE_DeathMsgGlobal") then {
  610. DZE_DeathMsgGlobal = false;
  611. };
  612. if (isNil "DZE_DeathMsgSide") then {
  613. DZE_DeathMsgSide = false;
  614. };
  615. if (isNil "DZE_DeathMsgTitleText") then {
  616. DZE_DeathMsgTitleText = false;
  617. };
  618. DZE_safeVehicle = ["ParachuteWest","ParachuteC"];
  619. };
  620.  
  621. if(!isDedicated) then {
  622.  
  623. dayz_spawnPos = getPosATL player;
  624.  
  625. dayz_buildingMonitor = []; //Buildings to check
  626. dayz_bodyMonitor = [];
  627.  
  628. // weather control var
  629. zeroPreviousWeather = [0,0,[0,0],0];
  630. zeroCurrentWeather = [0,0,[0,0],0];
  631.  
  632. if (DZE_MissionLootTable) then {
  633. dayz_baseTypes = getArray (missionConfigFile >> "CfgBuildingLoot" >> "Default" >> "zombieClass");
  634. } else {
  635. dayz_baseTypes = getArray (configFile >> "CfgBuildingLoot" >> "Default" >> "zombieClass");
  636. };
  637.  
  638.  
  639. //temperature variables
  640. dayz_temperatur = 36; //TeeChange
  641. dayz_temperaturnormal = 36; //TeeChange
  642. dayz_temperaturmax = 42; //TeeChange
  643. dayz_temperaturmin = 27; //TeeChange
  644.  
  645. //player special variables
  646. dayZ_lastPlayerUpdate = 0;
  647. dayZ_everyonesTents = [];
  648. dayz_hunger = 0;
  649. dayz_thirst = 0;
  650. dayz_combat = 0;
  651. dayz_preloadFinished = false;
  652. dayz_statusArray = [1,1];
  653. dayz_disAudial = 0;
  654. dayz_disVisual = 0;
  655. dayz_firedCooldown = 0;
  656. dayz_DeathActioned = false;
  657. dayz_canDisconnect = true;
  658. dayz_damageCounter = time;
  659. dayz_lastSave = time;
  660. dayz_isSwimming = true;
  661. dayz_isKneeling = false;
  662. dayz_isCrawling = false;
  663. dayz_PreviousTown = "Wilderness";
  664. dayz_currentDay = 0;
  665. dayz_hasLight = false;
  666. dayz_surfaceNoise = 0;
  667. dayz_surfaceType = "None";
  668. dayz_noPenalty = [];
  669. dayz_heavenCooldown = 0;
  670. deathHandled = false;
  671. dayz_lastHumanity = 0;
  672. dayz_guiHumanity = -90000;
  673. dayz_firstGroup = group player;
  674. dayz_originalPlayer = player;
  675. dayz_sourceBleeding = objNull;
  676. dayz_clientPreload = false;
  677. dayz_authed = false;
  678. dayz_panicCooldown = 0;
  679. dayz_areaAffect = 2.5;
  680. dayz_heartBeat = false;
  681. dayzClickTime = 0;
  682. //Current local
  683. dayz_spawnZombies = 0;
  684. dayz_swarmSpawnZombies = 0;
  685. //Max local
  686. dayz_maxLocalZombies = 30; // max quantity of Z controlled by local gameclient, used by player_spawnCheck. Below this limit we can spawn Z
  687. //Current NearBy
  688. dayz_CurrentNearByZombies = 0;
  689. //Max NearBy
  690. dayz_maxNearByZombies = 60; // max quantity of Z controlled by local gameclient, used by player_spawnCheck. Below this limit we can spawn Z
  691. //Current total
  692. dayz_currentGlobalZombies = 0;
  693. //Max global zeds.
  694. dayz_maxGlobalZeds = 3000;
  695. dayz_spawnDelay = 120;
  696. dayz_spawnWait = -120;
  697. dayz_lootDelay = 3;
  698. dayz_lootWait = -300;
  699. //used to count global zeds around players
  700. dayz_CurrentZombies = 0;
  701. //Used to limit overall zed counts
  702. dayz_tickTimeOffset = 0;
  703. dayz_currentWeaponHolders = 0;
  704. dayz_maxMaxWeaponHolders = 80;
  705. dayz_maxCurrentZeds = 0;
  706. dayz_inVehicle = false;
  707. dayz_Magazines = [];
  708. dayzGearSave = false;
  709. dayz_unsaved = false;
  710. dayz_scaleLight = 0;
  711. dayzDebug = false;
  712. dayzState = -1;
  713. //uiNamespace setVariable ['DAYZ_GUI_display',displayNull];
  714. //if (uiNamespace getVariable ['DZ_displayUI', 0] == 2) then {
  715. // dayzDebug = true;
  716. //};
  717.  
  718. DZE_ActionInProgress = false;
  719.  
  720. // DayZ Epoch Client only variables
  721. if(isNil "DZE_AllowForceSave") then {
  722. DZE_AllowForceSave = false;
  723. };
  724. if(isNil "DZE_AllowCargoCheck") then {
  725. DZE_AllowCargoCheck = true;
  726. };
  727. if(isNil "DZE_ForceNameTags") then {
  728. DZE_ForceNameTags = false;
  729. };
  730. if(isNil "DZE_ForceNameTagsOff") then {
  731. DZE_ForceNameTagsOff = false;
  732. };
  733. if(isNil "DZE_ForceNameTagsInTrader") then {
  734. DZE_ForceNameTagsInTrader = false;
  735. };
  736. if(isNil "DZE_HaloJump") then {
  737. DZE_HaloJump = true;
  738. };
  739.  
  740. if(isNil "DZE_AntiWallLimit") then {
  741. DZE_AntiWallLimit = 3;
  742. };
  743. if(isNil "DZE_requireplot") then {
  744. DZE_requireplot = 1;
  745. };
  746. if(isNil "DZE_R3F_WEIGHT") then {
  747. DZE_R3F_WEIGHT = true;
  748. };
  749.  
  750.  
  751. DZE_AntiWallCounter = 0;
  752.  
  753. DZE_FreshSpawn = false;
  754.  
  755. DZE_myHaloVehicle = objNull;
  756. dayz_myLiftVehicle = objNull;
  757.  
  758. DZE_Friends = [];
  759.  
  760. DZE_CanPickup = true;
  761. DZE_Q = false;
  762. DZE_Z = false;
  763.  
  764. DZE_Q_alt = false;
  765. DZE_Z_alt = false;
  766.  
  767. DZE_Q_ctrl = false;
  768. DZE_Z_ctrl = false;
  769.  
  770. DZE_5 = false;
  771. DZE_4 = false;
  772. DZE_6 = false;
  773.  
  774. DZE_cancelBuilding = false;
  775. DZE_PZATTACK = false;
  776.  
  777. DZE_trees = ["t_picea2s_snow.p3d","b_corylus.p3d","t_quercus3s.p3d","t_larix3s.p3d","t_pyrus2s.p3d","str_briza_kriva.p3d","dd_borovice.p3d","les_singlestrom_b.p3d","les_singlestrom.p3d","smrk_velky.p3d","smrk_siroky.p3d","smrk_maly.p3d","les_buk.p3d","str krovisko vysoke.p3d","str_fikovnik_ker.p3d","str_fikovnik.p3d","str vrba.p3d","hrusen2.p3d","str dub jiny.p3d","str lipa.p3d","str briza.p3d","p_akat02s.p3d","jablon.p3d","p_buk.p3d","str_topol.p3d","str_topol2.p3d","p_osika.p3d","t_picea3f.p3d","t_picea2s.p3d","t_picea1s.p3d","t_fagus2w.p3d","t_fagus2s.p3d","t_fagus2f.p3d","t_betula1f.p3d","t_betula2f.p3d","t_betula2s.p3d","t_betula2w.p3d","t_alnus2s.p3d","t_acer2s.p3d","t_populus3s.p3d","t_quercus2f.p3d","t_sorbus2s.p3d","t_malus1s.p3d","t_salix2s.p3d","t_picea1s_w.p3d","t_picea2s_w.p3d","t_ficusb2s_ep1.p3d","t_populusb2s_ep1.p3d","t_populusf2s_ep1.p3d","t_amygdalusc2s_ep1.p3d","t_pistacial2s_ep1.p3d","t_pinuse2s_ep1.p3d","t_pinuss3s_ep1.p3d","t_prunuss2s_ep1.p3d","t_pinusn2s.p3d","t_pinusn1s.p3d","t_pinuss2f.p3d","t_poplar2f_dead_pmc.p3d","misc_torzotree_pmc.p3d","misc_burnspruce_pmc.p3d","brg_cocunutpalm8.p3d","brg_umbrella_acacia01b.p3d","brg_jungle_tree_canopy_1.p3d","brg_jungle_tree_canopy_2.p3d","brg_cocunutpalm4.p3d","brg_cocunutpalm3.p3d","palm_01.p3d","palm_02.p3d","palm_03.p3d","palm_04.p3d","palm_09.p3d","palm_10.p3d","brg_cocunutpalm2.p3d","brg_jungle_tree_antiaris.p3d","brg_cocunutpalm1.p3d","str habr.p3d"];
  778. DZE_TEMP_treedmg = 1;
  779.  
  780. DZE_Surrender = false;
  781. DZE_Quarantine = false;
  782. DZE_InRadiationZone = false;
  783.  
  784. DZE_SaveTime = 30;
  785. };
  786. ColourVehicles = [
  787. "ATV_CZ_EP1",
  788. "ATV_US_EP1",
  789. "SUV_TK_CIV_EP1",
  790. "Mi17_Civilian_DZ",
  791. "UH60M_EP1_DZE",
  792. "Ka52",
  793. "Ka52Black",
  794. "UH1H_TK_EP1",
  795. "UH60M_MEV_EP1",
  796. "HMMWV_M998A2_SOV_DES_EP1_DZE",
  797. "HMMWV_M1151_M2_CZ_DES_EP1_DZE",
  798. "UAZ_MG_TK_EP1_DZE",
  799. "Ural_CDF",
  800. "Ural_TK_CIV_EP1",
  801. "Ural_UN_EP1",
  802. "V3S_Open_TK_CIV_EP1",
  803. "Kamaz",
  804. "MTVR_DES_EP1",
  805. "MH6J_DZ",
  806. "AH6X_DZ",
  807. "HMMWV_M1035_DES_EP1",
  808. "HMMWV_Ambulance",
  809. "HMMWV_Ambulance_CZ_DES_EP1",
  810. "HMMWV_DES_EP1",
  811. "HMMWV_DZ",
  812. "hilux1_civil_3_open_EP1",
  813. "hilux1_civil_1_open",
  814. "datsun1_civil_1_open",
  815. "Pickup_PK_GUE_DZE",
  816. "Pickup_PK_INS_DZE",
  817. "Pickup_PK_TK_GUE_EP1_DZE",
  818. "Offroad_DSHKM_Gue_DZE",
  819. "LAV25_HQ",
  820. "BTR90_HQ_DZE",
  821. "M1133_MEV_EP1",
  822. "pook_H13_amphib",
  823. "pook_H13_civ",
  824. "pook_H13_medevac_CIV",
  825. "pook_H13_transport",
  826. "pook_H13_gunship_PMC",
  827. "pook_H13_transport_INS",
  828. "VWGolf"
  829. ];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement