From b8f201d986068d50493ea645c47f6d9c0b148d45 Mon Sep 17 00:00:00 2001 From: worldwidesorrow Date: Fri, 15 Sep 2023 12:05:55 -0500 Subject: [PATCH] Add namalsk POIs Fixed Object A2 scenery and converted to compact arrays. Fixed floating objects, objects sticking through walls, and disabled simulation to stop bouncing of some objects. Objects that originally used setPosASL converted to setPosATL. Added some map fixes for Object A2 ladder shaft fall hazards and barracks entrances that required vaulting to enter. Added rail gun spawning with configurable chance. The POI call in init.sqf has the individual POI files listed in an array so server owners can comment them out or remove them if they don't want them. --- .../system/mission/namalsk/poi/A2Objects.sqf | 108 ++++++++++++++++++ .../system/mission/namalsk/poi/A2RailGun.sqf | 11 ++ .../system/mission/namalsk/poi/init.sqf | 16 +++ .../system/mission/namalsk/poi/mapFixes.sqf | 18 +++ .../DayZ_Epoch_15.namalsk/configVariables.sqf | 2 +- .../MPMissions/DayZ_Epoch_15.namalsk/init.sqf | 8 +- 6 files changed, 161 insertions(+), 2 deletions(-) create mode 100644 SQF/dayz_code/system/mission/namalsk/poi/A2Objects.sqf create mode 100644 SQF/dayz_code/system/mission/namalsk/poi/A2RailGun.sqf create mode 100644 SQF/dayz_code/system/mission/namalsk/poi/init.sqf create mode 100644 SQF/dayz_code/system/mission/namalsk/poi/mapFixes.sqf diff --git a/SQF/dayz_code/system/mission/namalsk/poi/A2Objects.sqf b/SQF/dayz_code/system/mission/namalsk/poi/A2Objects.sqf new file mode 100644 index 000000000..015d8655b --- /dev/null +++ b/SQF/dayz_code/system/mission/namalsk/poi/A2Objects.sqf @@ -0,0 +1,108 @@ +// Object A2 scenery + +local _obj = objNull; + +{ + _obj = (_x select 0) createVehicle [0,0,0]; + if (count _x == 4) then { + _obj setDir (_x select 3); + }; + _obj setVectorUp (_x select 2); + _obj setPosATL (_x select 1); + _obj enableSimulation false; +} count [ + // First floor + ["ns_zarivka",[4983.9385,6614.6343,27.40],[0,0,1]], + ["ns_zarivka",[4986.8208,6619.5962,27.4],[0,0,1]], + ["ns_zarivka",[4990.2695,6616.0361,27.4],[0,0,1]], + ["ns_zarivka",[4978.6118,6626.6675,27.4],[0,0,1]], + ["ns_zarivka",[4978.8086,6630.834,27.4],[0,0,1]], + ["ns_zarivka",[4979.1362,6635.5249,27.4],[0,0,1]], + ["FoldChair",[4974.1978,6607.0635,23.48],[0,0,1],93], + ["ns_zarivka",[4975.1152,6606.9126,27.40],[0,0,1]], + ["Desk",[4973.9487,6610.4839,23.4],[0,0,1],180], + ["Desk",[4973.9219,6603.0215,23.6],[0,0,1]], + ["WoodChair",[4973.8438,6603.9565,23.6],[0,0,1]], + ["SatPhone",[4973.9072,6603.0386,24.42],[0,0,1],180], + ["Notebook",[4973.9404,6610.4087,24.33],[0,0,1],192], + ["EvMoscow",[4974.6909,6610.3784,24.33],[0,0,1]], + ["FoldChair",[4973.9233,6609.4385,23.48],[0,0,1],172], + ["Misc_cargo_cont_tiny",[4986.6396,6603.7856,23.5],[0,0,1],175], + ["Misc_cargo_cont_tiny",[4986.5288,6606.1143,23.5],[0,0,1],88], + ["FoldChair",[4984.2954,6604.1353,23.48],[0,0,1],181], + ["Misc_cargo_cont_net1",[4981.3809,6616.6499,23.45],[0,0,1],88], + ["Misc_cargo_cont_net1",[4981.187,6612.5479,23.45],[0,0,1]], + ["FoldTable",[4973.6689,6614.916,23.48],[0,0,1],269], + ["Barrels",[4973.4341,6616.8174,23.48],[0,0,1],92], + ["Barrels",[4977.7178,6612.7295,23.48],[0,0,1],92], + ["Fuel_can",[4973.0981,6613.0313,23.48],[0,0,1],92], + ["Fuel_can",[4974.1353,6613.1196,23.48],[0,0,1],69], + ["Fuel_can",[4973.6313,6612.6899,23.48],[0,0,1],69], + ["Paleta1",[4971.3,6612.9463,23.48],[0,0,1],92], + ["Paleta1",[4971.3,6614.7827,23.48],[0,0,1],92], + ["Fuel_can",[4971.5698,6614.4155,23.68],[0,0,1],165], + ["Fuel_can",[4971.44,6612.75,23.68],[0,0,1]], + ["Fuel_can",[4971.3984,6613.2762,23.68],[0,0,1]], + ["Land_Barrel_water",[4970.8035,6612.0013,23.68],[0,0,1]], + ["Land_Barrel_water",[4971.627,6612.0021,23.68],[0,0,1]], + ["Land_Barrel_sand",[4972.519,6611.8691,23.48],[0,0,1]], + ["Land_Barrel_sand",[4970.8052,6613.3919,23.68],[0,0,1]], + ["Land_Barrel_sand",[4971.2021,6616,23.48],[0,0,1]], + ["Barrel4",[4971.5132,6614.8403,23.7],[0,0,1]], + ["Misc_cargo_cont_net1",[4969.7671,6620.5503,23.45],[0,0,1],265], + ["Misc_cargo_cont_net1",[4994.9761,6621.8188,23.45],[0,0,1],88], + ["Misc_cargo_cont_net1",[4992.0557,6618.3994,23.45],[0,0,1],88], + ["Misc_cargo_cont_net1",[4992.0996,6621.8604,23.45],[0,0,1],88], + ["ns_kompiky",[4973.3091,6632.8042,23.6],[0,0,1],-88], + ["ns_kompiky",[4976.229,6632.6499,23.6],[0,0,1],-267], + ["ns_kompiky",[4977.6191,6632.4976,23.6],[0,0,1],-446], + ["Fuel_can",[4972.9258,6627.8628,23.48],[0,0,1]], + ["Misc_cargo_cont_tiny",[4981.8286,6637.7822,23.45],[0,0,1],175], + ["Misc_cargo_cont_tiny",[4981.5898,6629.4341,23.50],[0,0,1],175], + ["Notebook",[4981.0991,6629.2246,25.15],[0,0,1],-103], + ["WoodChair",[4973.5703,6628.9707,23.6],[0,0,1],102], + ["WoodChair",[4973.6123,6629.8154,23.6],[0,0,1],82], + ["Land_Barrel_sand",[4965.5273,6617.0273,23.48],[0,0,1]], + ["Land_Barrel_sand",[4965.7422,6616.0068,23.48],[0,0,1]], + ["Land_Barrel_water",[4963.6167,6618.1294,23.48],[0,0,1]], + ["Land_Barrel_water",[4963.3208,6617.189,23.48],[0,0,1]], + ["Land_Barrel_water",[4963.3745,6615.9521,23.48],[0,0,1]], + ["Paleta2",[4969.11,6612.95,23.48],[0,0,1],90], + ["Land_Barrel_sand",[4966.5674,6612.2695,23.48],[0,0,1]], + ["Land_Barrel_sand",[4967.2222,6612.2969,23.48],[0,0,1]], + // Second floor + ["Land_Barrel_water",[4975.7256,6620.6211,16.4],[0,0,1]], + ["Land_Barrel_sand",[4975.98,6621.3604,16.4],[0,0,1]], + ["Land_Barrel_sand",[4976.5303,6620.7676,16.4],[0,0,1]], + ["Land_Barrel_sand",[4981.1943,6644.4468,17.23],[0,0,1]], + ["Land_Barrel_sand",[4980.1802,6644.6431,17.23],[0,0,1]], + ["Land_Barrel_sand",[4979.2642,6645.1338,17.23],[0,0,1]], + ["Land_Barrel_empty",[4981.0571,6645.0645,17.23],[0,0,1]], + ["Land_Barrel_sand",[4980.1592,6645.5347,17.23],[0,0,1]], + ["Land_Barrel_sand",[4982.0249,6644.4292,17.23],[0,0,1]], + ["Land_Barrel_sand",[4978.6226,6648.9121,17.23],[0,0,1],15], + ["Land_Barrel_empty",[4978.06,6649.4,17.23],[0,0,1],150], + ["Land_Barrel_sand",[4979.49,6648.97,17.23],[0,0,1],210], + ["Barrels",[4983.1167,6646.6553,17.23],[0,0,1],6], + ["Barrel4",[4983.7129,6646.6138,17.23],[0,0,1]], + ["Barrel5",[4984.8701,6646.5146,17.23],[0,0,1]], + ["Barrel5",[4984.1704,6645.8159,17.23],[0,0,1]], + ["FoldTable",[4984.21,6605.85,23.48],[0,0,1],85], + ["PowerGenerator",[4977.99,6617.47,23.48],[0,0,1],92], + ["Paleta2",[4971.95,6617.15,23.48],[0,0,1],181], + ["Paleta2",[4964.46,6616.27,23.48],[0,0,1],181], + ["Paleta2",[4969.77,6623.07,23.48],[0,0,1],0], + ["ns_servery",[4974.46,6622.96,23.48],[0,0,1],-447], + ["ns_servery",[4975.82,6622.8,23.48],[0,0,1],-447], + ["ns_servery",[4972.88,6626.27,23.48],[0,0,1]], + ["Misc_cargo_cont_tiny",[4977.7358,6624.0195,17.2],[0,0,1],-214], + ["Misc_cargo_cont_tiny",[4976.4238,6625.7964,17.2],[0,0,1],-224], + ["Misc_cargo_cont_net1",[4973.0718,6624.5732,16.4],[0,0,1],-219], + ["Misc_cargo_cont_net1",[4974.8711,6622.3086,16.4],[0,0,1],-219], + ["Misc_cargo_cont_net1",[4985.3965,6608.3174,16.4],[0,0,1],-217], + ["Misc_cargo_cont_net1",[4984.2354,6609.8521,16.4],[0,0,1],-217], + ["Misc_cargo_cont_net1",[4981.4805,6613.9399,16.4],[0,0,1],-307], + ["Misc_cargo_cont_net1",[4980.3193,6615.4746,16.4],[0,0,1],-217] +]; + +//diag_log "[NAC AII SERVER] :: AII objects has been spawned."; \ No newline at end of file diff --git a/SQF/dayz_code/system/mission/namalsk/poi/A2RailGun.sqf b/SQF/dayz_code/system/mission/namalsk/poi/A2RailGun.sqf new file mode 100644 index 000000000..a8c23df17 --- /dev/null +++ b/SQF/dayz_code/system/mission/namalsk/poi/A2RailGun.sqf @@ -0,0 +1,11 @@ +// DZE Namalsk A2 Rail Gun Spawn Script by JasonTM +// Random Chance of an "Alien Super Weapon" spawning on the second floor of Object A2. + +if (random 1 <= _this) then { + local _wh = "WeaponHolder" createVehicle [0,0,0]; + _wh setPosATL [4978.17, 6647.25, 17.2435]; + _wh setVariable ["permaLoot",true]; + _wh addWeaponCargoGlobal ["nsw_er7s",1]; + _wh addMagazineCargoGlobal ["nsw_er7mm",2]; + //diag_log "Rail gun has spawned at object AII"; +}; \ No newline at end of file diff --git a/SQF/dayz_code/system/mission/namalsk/poi/init.sqf b/SQF/dayz_code/system/mission/namalsk/poi/init.sqf new file mode 100644 index 000000000..2c17b7510 --- /dev/null +++ b/SQF/dayz_code/system/mission/namalsk/poi/init.sqf @@ -0,0 +1,16 @@ +/* + Add POI objects on server machine only. + Do not use execVM. This must be unscheduled to finish before server_monitor.sqf runs (vehicles or players can spawn on top) + Do not use createVehicleLocal for these. They contain trees and buildings (need chopped/destroyed status synchronized for all clients) +*/ + +{ + if (typeName _x == "ARRAY") then { + (_x select 1) call compile preprocessFileLineNumbers ("\z\addons\dayz_code\system\mission\namalsk\poi\" + (_x select 0) + ".sqf"); + } else { + call compile preprocessFileLineNumbers ("\z\addons\dayz_code\system\mission\namalsk\poi\" + _x + ".sqf"); + }; + + //This is needed to process all setVehicleInit commands + processInitCommands; +} forEach _this; \ No newline at end of file diff --git a/SQF/dayz_code/system/mission/namalsk/poi/mapFixes.sqf b/SQF/dayz_code/system/mission/namalsk/poi/mapFixes.sqf new file mode 100644 index 000000000..6140817ba --- /dev/null +++ b/SQF/dayz_code/system/mission/namalsk/poi/mapFixes.sqf @@ -0,0 +1,18 @@ +// Map fixes - objectA2 fall hazards and elevated Northern Army Base barracks entrances that you must vault to enter. + +local _obj = objNull; + +{ + _obj = (_x select 0) createVehicle [0,0,0]; + _obj setVectorDirAndUp (_x select 2); + _obj setPosATL (_x select 1); + _obj enableSimulation false; +} count [ + ["WoodFloorQuarter_DZ",[4990.341,6614.789,42.487],[[0.034,-0.999,0],[0,0,1]]], + ["WoodFloorQuarter_DZ",[4990.185,6616.587,41.549],[[-0.02,0.573,-0.819],[-0.028,0.819,0.574]]], + ["WoodFloorQuarter_DZ",[4991.7,6617.526,40.687],[[-0.98,0.199,0],[0,0,1]]], + ["WoodFloorQuarter_DZ",[4965.494,6613.854,23.28],[[-0.78,-0.62,0.087],[0.068,0.054,0.996]]], + ["WoodFloorQuarter_DZ",[4803.953,10802.216,-0.267],[[-0.85,0.459,0.259],[0.228,-0.123,0.966]]], + ["WoodFloorQuarter_DZ",[4809.562,10811.947,-0.118],[[-0.844,0.469,0.259],[0.226,-0.126,0.966]]], + ["WoodFloorQuarter_DZ",[4990.31,6612.955,41.728],[[-0.024,0.707,0.707],[0.024,-0.707,0.707]]] +]; \ No newline at end of file diff --git a/Server Files/MPMissions/DayZ_Epoch_15.namalsk/configVariables.sqf b/Server Files/MPMissions/DayZ_Epoch_15.namalsk/configVariables.sqf index 944674450..0cc2cd3ed 100644 --- a/Server Files/MPMissions/DayZ_Epoch_15.namalsk/configVariables.sqf +++ b/Server Files/MPMissions/DayZ_Epoch_15.namalsk/configVariables.sqf @@ -118,7 +118,7 @@ if (isServer) then { ["any","any","any","any",-1,"CrashSites"] ]; - dayz_POIs = false; //Adds Point of Interest map additions (negatively impacts FPS) + dayz_POIs = true; //Adds Point of Interest map additions (negatively impacts FPS) DynamicVehicleDamageLow = 0; // Min damage random vehicles can spawn with DynamicVehicleDamageHigh = 100; // Max damage random vehicles can spawn with DynamicVehicleFuelLow = 0; // Min fuel random vehicles can spawn with diff --git a/Server Files/MPMissions/DayZ_Epoch_15.namalsk/init.sqf b/Server Files/MPMissions/DayZ_Epoch_15.namalsk/init.sqf index 87dc25208..6d8ef94b4 100644 --- a/Server Files/MPMissions/DayZ_Epoch_15.namalsk/init.sqf +++ b/Server Files/MPMissions/DayZ_Epoch_15.namalsk/init.sqf @@ -53,7 +53,13 @@ initialized = true; if (dayz_REsec == 1) then {call compile preprocessFileLineNumbers "\z\addons\dayz_code\system\REsec.sqf";}; if (isServer) then { - if (dayz_POIs) then {call compile preprocessFileLineNumbers "\z\addons\dayz_code\system\mission\chernarus\poi\init.sqf";}; + if (dayz_POIs) then { + [ + "A2Objects", // Object A2 objects that were included by Sumrak in Namalsk Crisis. + ["A2RailGun",.25], // Spawns rail gun on the second floor of object A2. Default chance: .25 (25%) + "mapFixes" // Fixes entrances to some barracks and prevents fall hazards in Object A2. + ] call compile preprocessFileLineNumbers "\z\addons\dayz_code\system\mission\namalsk\poi\init.sqf"; + }; call compile preprocessFileLineNumbers "\z\addons\dayz_server\system\dynamic_vehicle.sqf"; call compile preprocessFileLineNumbers "\z\addons\dayz_server\system\server_monitor.sqf"; execVM "\z\addons\dayz_server\traders\namalsk.sqf"; //Add trader agents