diff --git a/addons/Hellfire/$PBOPREFIX$ b/addons/Hellfire/$PBOPREFIX$ new file mode 100644 index 0000000..b0f4c14 --- /dev/null +++ b/addons/Hellfire/$PBOPREFIX$ @@ -0,0 +1 @@ +z\TF47\addons\Hellfire \ No newline at end of file diff --git a/addons/hellfires/ACE_GuidanceConfig.hpp b/addons/Hellfire/ACE_GuidanceConfig.hpp similarity index 100% rename from addons/hellfires/ACE_GuidanceConfig.hpp rename to addons/Hellfire/ACE_GuidanceConfig.hpp diff --git a/addons/hellfires/CfgAmmo.hpp b/addons/Hellfire/CfgAmmo.hpp similarity index 100% rename from addons/hellfires/CfgAmmo.hpp rename to addons/Hellfire/CfgAmmo.hpp diff --git a/addons/hellfires/CfgMagazineWells.hpp b/addons/Hellfire/CfgMagazineWells.hpp similarity index 100% rename from addons/hellfires/CfgMagazineWells.hpp rename to addons/Hellfire/CfgMagazineWells.hpp diff --git a/addons/hellfires/CfgMagazines.hpp b/addons/Hellfire/CfgMagazines.hpp similarity index 100% rename from addons/hellfires/CfgMagazines.hpp rename to addons/Hellfire/CfgMagazines.hpp diff --git a/addons/hellfires/CfgWeapons.hpp b/addons/Hellfire/CfgWeapons.hpp similarity index 100% rename from addons/hellfires/CfgWeapons.hpp rename to addons/Hellfire/CfgWeapons.hpp diff --git a/addons/hellfires/config.cpp b/addons/Hellfire/config.cpp similarity index 100% rename from addons/hellfires/config.cpp rename to addons/Hellfire/config.cpp diff --git a/addons/hellfires/script_component.hpp b/addons/Hellfire/script_component.hpp similarity index 91% rename from addons/hellfires/script_component.hpp rename to addons/Hellfire/script_component.hpp index cd9aab1..d113567 100644 --- a/addons/hellfires/script_component.hpp +++ b/addons/Hellfire/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT hellfires +#define COMPONENT Hellfire #include "\z\TF47\addons\main\script_mod.hpp" #define DEBUG_MODE_FULL diff --git a/addons/ITCCompat/$PBOPREFIX$ b/addons/ITCCompat/$PBOPREFIX$ new file mode 100644 index 0000000..98d59b4 --- /dev/null +++ b/addons/ITCCompat/$PBOPREFIX$ @@ -0,0 +1 @@ +z\TF47\addons\ITCCompat \ No newline at end of file diff --git a/addons/itc_compat/CfgAmmo.hpp b/addons/ITCCompat/CfgAmmo.hpp similarity index 98% rename from addons/itc_compat/CfgAmmo.hpp rename to addons/ITCCompat/CfgAmmo.hpp index f5a189b..b8d5678 100644 --- a/addons/itc_compat/CfgAmmo.hpp +++ b/addons/ITCCompat/CfgAmmo.hpp @@ -1,5 +1,4 @@ class CfgAmmo { - class itc_land_155mm; class itc_land_155mm_m109: itc_land_155mm { model = "\A3\Weapons_F\Ammo\shell.p3d"; @@ -32,7 +31,7 @@ class CfgAmmo { "rhs_ammo_sub_blu97",0.3, "rhs_ammo_m85_submunition",0.6, "rhs_ammo_uxo_ao1_2_deploy",0.1 - }; + }; }; class itc_land_155mm_dpicm_pgm_helper_m109: itc_land_155mm_dpicm_helper { @@ -41,7 +40,7 @@ class CfgAmmo { "rhs_ammo_sub_blu97",0.3, "rhs_ammo_m85_submunition",0.6, "rhs_ammo_uxo_ao1_2_deploy",0.1 - }; + }; }; class Mine_155mm_AMOS_range; @@ -58,5 +57,4 @@ class CfgAmmo { model = "\rhsusf\addons\rhsusf_weapons\FGM148\fgm148_missile"; hit = 2000; }; - }; diff --git a/addons/ITCCompat/CfgITCLandBalistics.hpp b/addons/ITCCompat/CfgITCLandBalistics.hpp new file mode 100644 index 0000000..500c92d --- /dev/null +++ b/addons/ITCCompat/CfgITCLandBalistics.hpp @@ -0,0 +1,28 @@ +class itc_land_ballistics { + class batteryTypes { + class RHS_M109_M284 { + displayName = "M109A6 - 155mmm Howitzer"; + type = "cannon"; + ammunition[] = { + "itc_land_m109hex", + "itc_land_m109icm", + + "itc_land_m109smo", + "itc_land_m109ill", + + "itc_land_m109mat", + "itc_land_m109map", + + "itc_land_m109pgm", + "itc_land_m109icmpgm", + + "itc_land_m109lgm", + "itc_land_m109lgmat", + + "itc_land_m109ext", + "itc_land_m109fal" + }; + weaponClass = "itc_land_rhs_weap_m284"; + }; + }; +}; \ No newline at end of file diff --git a/addons/itc_compat/CfgMagazines.hpp b/addons/ITCCompat/CfgMagazines.hpp similarity index 100% rename from addons/itc_compat/CfgMagazines.hpp rename to addons/ITCCompat/CfgMagazines.hpp diff --git a/addons/itc_compat/CfgVehicles.hpp b/addons/ITCCompat/CfgVehicles.hpp similarity index 100% rename from addons/itc_compat/CfgVehicles.hpp rename to addons/ITCCompat/CfgVehicles.hpp diff --git a/addons/itc_compat/CfgWeapons.hpp b/addons/ITCCompat/CfgWeapons.hpp similarity index 100% rename from addons/itc_compat/CfgWeapons.hpp rename to addons/ITCCompat/CfgWeapons.hpp diff --git a/addons/itc_compat/CfgWeapons_howitzers_magazinesm109.hpp b/addons/ITCCompat/CfgWeapons_howitzers_magazinesm109.hpp similarity index 100% rename from addons/itc_compat/CfgWeapons_howitzers_magazinesm109.hpp rename to addons/ITCCompat/CfgWeapons_howitzers_magazinesm109.hpp diff --git a/addons/itc_compat/config.cpp b/addons/ITCCompat/config.cpp similarity index 92% rename from addons/itc_compat/config.cpp rename to addons/ITCCompat/config.cpp index 3484bbe..ae4cecd 100644 --- a/addons/itc_compat/config.cpp +++ b/addons/ITCCompat/config.cpp @@ -7,7 +7,7 @@ class CfgPatches { requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"rhsusf_main", "rhsusf_c_troops", "A3_Armor_F_Slammer", "rhsusf_c_heavyweapons","rhsusf_c_m109","itc_land_veh_sights","itc_land_sphammohandler","itc_land_rhsusaf_m109"}; author = "TF47 Dev Team"; - authors[] = {"TF47 -Sonic-","TF47 Desty"}; + authors[] = {"TF47 Desty"}; VERSION_CONFIG; }; }; diff --git a/addons/rhs_compat/script_component.hpp b/addons/ITCCompat/script_component.hpp similarity index 91% rename from addons/rhs_compat/script_component.hpp rename to addons/ITCCompat/script_component.hpp index 12c5b44..f1603ab 100644 --- a/addons/rhs_compat/script_component.hpp +++ b/addons/ITCCompat/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT rhs_compat +#define COMPONENT ITCCompat #include "\z\TF47\addons\main\script_mod.hpp" #define DEBUG_MODE_FULL diff --git a/addons/ITCExpansionGuidanceFuzes/$PBOPREFIX$ b/addons/ITCExpansionGuidanceFuzes/$PBOPREFIX$ new file mode 100644 index 0000000..b8000b3 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/$PBOPREFIX$ @@ -0,0 +1 @@ +z\TF47\addons\ITCExpansionGuidanceFuzes \ No newline at end of file diff --git a/addons/ITCExpansionGuidanceFuzes/CfgAmmo.hpp b/addons/ITCExpansionGuidanceFuzes/CfgAmmo.hpp new file mode 100644 index 0000000..2e7c407 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgAmmo.hpp @@ -0,0 +1,219 @@ +class CfgAmmo { + //Base Classes - Howitzer + class FlareCore; + class Sh_155mm_AMOS; + class Smoke_120mm_AMOS_White; + class Mine_155mm_AMOS_range; + class AT_Mine_155mm_AMOS_range; + class Cluster_155mm_AMOS; + //Base Classes - Missile + + + + //155mm Ammo + class itc_land_155mm: Sh_155mm_AMOS { + //artilleryLock = 0; + //airFriction = -0.0000395; + //sideAirFriction = 1; + //whistleOnFire = 1; + //whistleDist = 500; + suppressionRadiusHit = 100; + ace_frag_enabled = 1; + ace_frag_classes[] = {ACE_frag_large, ACE_frag_large, ACE_frag_large_HD, ACE_frag_large, ACE_frag_medium_HD, ACE_frag_medium_HD, ACE_frag_medium, ACE_frag_huge, ACE_frag_huge_HD, ACE_frag_huge}; + ace_frag_metal = 36000; + ace_frag_charge = 10800; + ace_frag_gurney_c = 2440; + ace_frag_gurney_k = 1/2; + ace_rearm_caliber = 155; + }; + class itc_land_155mm_inert: itc_land_155mm { + indirectHitRange = 1; + indirectHit = 100; + explosionEffects = ""; + ace_frag_enabled = 0; + explosive = 0; + CraterEffects = "NoCrater"; + ace_rearm_caliber = 155; + }; + class itc_land_155mm_helper: itc_land_155mm { + explosionTime = 0.0001; + }; + class itc_land_155mm_smoke : Smoke_120mm_AMOS_White { + ace_frag_enabled = 0; + triggerTime = 0.05; + triggerDistance = 0.1; + submunitionConeType[] = {"poissondisc",20}; + submunitionConeAngle = 4; + //submunitionAmmo = "SmokeLauncherAmmo"; + ace_rearm_caliber = 155; + }; + class itc_land_155mm_illum: FlareCore { + model = "\A3\weapons_f\ammo\shell"; + effectFlare = "CounterMeasureFlare"; + aimAboveTarget[] = {50, 80, 140, 200, 260, 320, 380}; + aimAboveDefault = 4; + triggerSpeedCoef = 1; + triggerTime = 0.001; + lightColor[] = {0.95, 0.95, 1, 0.5}; + smokeColor[] = {1, 1, 1, 0.5}; + brightness = 200; + //intensity = 180000; + //flareSize = 500; + timeToLive = 90; + ace_rearm_caliber = 155; + //explosionTime = 1; + }; + class itc_land_155mm_dpicm_helper: Cluster_155mm_AMOS { + triggerTime = 0.05; + triggerDistance = 0.1; + submunitionConeType[] = {"poissondisc",100}; + submunitionAmmo[] = {"Mo_cluster_AP",0.33,"Mo_cluster_Bomb_01_F",0.66,"Mo_cluster_AP_UXO_deploy",0.07}; + submunitionConeAngle = 4; + }; + class itc_land_155mm_fascam_ap_helper : Mine_155mm_AMOS_range { + triggerTime = 0.05; + }; + class itc_land_155mm_fascam_at_helper : AT_Mine_155mm_AMOS_range { + triggerTime = 0.05; + }; + /* + class itc_land_155mm_apf_helper: Cluster_155mm_AMOS { + triggerTime = 0.05; + triggerDistance = 0.1; + submunitionConeType[] = {"poissondisc",1500}; + submunitionAmmo[] = {"ITC_APF_Submunition",0.33}; + submunitionConeAngle = 7; + submunitionInitSpeed = 880; + }; + class B_127x99_Ball; + class ITC_APF_Submunition : B_127x99_Ball { + caliber = 3.5; + initSpeed = 880; + }; + */ + + //105mm + class itc_land_105mm: itc_land_155mm { + hit = 210; + indirectHit = 75; + indirectHitRange = 20; + ace_frag_enabled = 1; + ace_frag_classes[] = {ACE_frag_large, ACE_frag_large, ACE_frag_large_HD, ACE_frag_large, ACE_frag_medium_HD, ACE_frag_medium_HD, ACE_frag_medium, ACE_frag_huge, ACE_frag_huge_HD, ACE_frag_huge}; + ace_frag_metal = 16000; + ace_frag_charge = 2900; + ace_frag_gurney_c = 2440; + ace_frag_gurney_k = 1/2; + ace_rearm_caliber = 105; + }; + class itc_land_105mm_inert: itc_land_155mm_inert { + ace_rearm_caliber = 105; + }; + class itc_land_105mm_helper: itc_land_105mm { + explosionTime = 0.0001; + }; + class itc_land_105mm_smoke : itc_land_155mm_smoke { + submunitionConeType[] = {"poissondisc",10}; + ace_rearm_caliber = 105; + }; + class itc_land_105mm_illum: itc_land_155mm_illum { + brightness = 200; + ace_rearm_caliber = 105; + }; + class itc_land_105mm_dpicm_helper: itc_land_155mm_dpicm_helper { + submunitionConeType[] = {"poissondisc",42}; + ace_rearm_caliber = 105; + }; + + //122mm + class itc_land_122mm: itc_land_105mm { + hit = 250; + indirectHit = 85; + indirectHitRange = 22; + ace_rearm_caliber = 122; + }; + class itc_land_122mm_inert: itc_land_105mm_inert { + ace_rearm_caliber = 122; + }; + class itc_land_122mm_helper: itc_land_122mm { + explosionTime = 0.0001; + }; + class itc_land_122mm_smoke : itc_land_105mm_smoke { + ace_rearm_caliber = 122; + }; + class itc_land_122mm_illum: itc_land_105mm_illum { + ace_rearm_caliber = 122; + }; + class itc_land_122mm_dpicm_helper: itc_land_105mm_dpicm_helper { + ace_rearm_caliber = 122; + }; + + //127mm + class itc_land_127mm: itc_land_155mm { + hit = 300; + indirectHit = 95; + indirectHitRange = 25; + ace_frag_metal = 16000; + ace_frag_charge = 2900; + ace_frag_gurney_c = 2440; + ace_frag_gurney_k = 1/2; + ace_rearm_caliber = 127; + }; + class itc_land_127mm_inert: itc_land_155mm_inert { + ace_rearm_caliber = 127; + }; + class itc_land_127mm_helper: itc_land_105mm { + explosionTime = 0.0001; + }; + class itc_land_127mm_smoke : itc_land_155mm_smoke { + submunitionConeType[] = {"poissondisc",10}; + ace_rearm_caliber = 127; + }; + class itc_land_127mm_illum: itc_land_155mm_illum { + brightness = 200; + ace_rearm_caliber = 127; + }; + class itc_land_127mm_dpicm_helper: itc_land_155mm_dpicm_helper { + submunitionConeType[] = {"poissondisc",42}; + ace_rearm_caliber = 127; + }; + + //MLRS + //230mm + class R_230mm_HE; + class itc_land_230mm_he : R_230mm_HE { + hit = 1200; + indirectHit = 800; + indirectHitRange = 30; + simulation = "shotShell"; + }; + class itc_land_230mm_helper : itc_land_155mm_helper { + indirectHit = 800; + indirectHitRange = 30; + }; + class itc_land_230mm_inert : itc_land_230mm_he { + indirectHitRange = 1; + indirectHit = 100; + explosionEffects = ""; + ace_frag_enabled = 0; + explosive = 0; + CraterEffects = "NoCrater"; + }; + class R_230mm_Cluster; + class itc_land_230mm_icm_helper: R_230mm_Cluster { + triggerTime = 0.05; + triggerDistance = 0.1; + submunitionConeType[] = {"poissondisc",240}; + submunitionAmmo[] = {"Mo_cluster_AP",0.33,"Mo_cluster_Bomb_01_F",0.66,"Mo_cluster_AP_UXO_deploy",0.07}; + submunitionConeAngle = 5; + }; + + class itc_land_230mm_fascam_ap_helper : Mine_155mm_AMOS_range { + triggerTime = 0.05; + submunitionConeType[] = {"randomcenter",50}; + }; + + class itc_land_230mm_fascam_at_helper : AT_Mine_155mm_AMOS_range { + triggerTime = 0.05; + submunitionConeType[] = {"randomcenter",50}; + }; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgFunctions.hpp b/addons/ITCExpansionGuidanceFuzes/CfgFunctions.hpp new file mode 100644 index 0000000..68ba24f --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgFunctions.hpp @@ -0,0 +1,17 @@ +class CfgFunctions { + class TF47 { + class ITCExpansionGuidanceFuzes { + file = "z\TF47\addons\ITCExpansionGuidanceFuzes\functions"; + class fired {}; + class firedMof35 {}; //FOR REGULAR SHELLS LIKE HE + class firedMof35Mod3 {}; //FOR CARGO SHELLS LIKE EXTRA + class firedSAM35{}; //FOR THINGS WOT ARE SHOT AT AIRCRAFT + class fuzeDelay {}; + class fuzeTime {}; + class fuzeProx {}; + class adjustMuzzleVelG15x {}; + class deployExtra {}; + class deployFalat {}; + }; + }; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines.hpp new file mode 100644 index 0000000..a3ce77e --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines.hpp @@ -0,0 +1,16 @@ +class CfgMagazines { + class VehicleMagazine; + class itc_land_how_mag : VehicleMagazine { + scope = 2; + count = 1; + nameSound = "cannon"; + dispersionEvent = "itc_land_veh_weapons_fnc_adjustMuzzleVelG15x"; + itc_land_heightModifier = 0; + itc_land_timeModifier = 0; + }; + #include "CfgMagazines_155mm.hpp" + #include "CfgMagazines_152mm.hpp" + #include "CfgMagazines_122mm.hpp" + #include "CfgMagazines_127mm.hpp" + #include "CfgMagazines_230mm.hpp" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_105mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_105mm.hpp new file mode 100644 index 0000000..3413419 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_105mm.hpp @@ -0,0 +1,62 @@ + class itc_land_g105hex: itc_land_g155hex { + author = "Toadball"; + displayName = "G105 HE"; + displayNameShort = "G105 HE"; + ammo = "itc_land_105mm"; + itc_land_submunition = "itc_land_105mm_helper"; + itc_land_charge_format = "itc_land_g105hex_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_105\list.sqf"; + }; + class itc_land_g105hex_chg1: itc_land_g105hex { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g105hex_chg2: itc_land_g105hex { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g105hex_chg3: itc_land_g105hex { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g105hex_chg4: itc_land_g105hex { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g105hex_chg5: itc_land_g105hex { initSpeed = 320; itc_land_CountInAH = 0; }; + + class itc_land_g105smo: itc_land_g155smo { + author = "Toadball"; + displayName = "G105 SMOKE"; + displayNameShort = "G105 SMOKE"; + ammo = "itc_land_127mm_smoke"; + itc_land_charge_format = "itc_land_g105smo_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_105\list.sqf"; + }; + class itc_land_g105smo_chg1: itc_land_g105smo { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g105smo_chg2: itc_land_g105smo { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g105smo_chg3: itc_land_g105smo { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g105smo_chg4: itc_land_g105smo { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g105smo_chg5: itc_land_g105smo { initSpeed = 320; itc_land_CountInAH = 0; }; + + class itc_land_g105ill: itc_land_g155ill { + author = "Toadball"; + displayName = "G105 ILLUM"; + displayNameShort = "G105 ILLUM"; + ammo = "itc_land_105mm_illum"; + itc_land_charge_format = "itc_land_g105ill_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_105\list.sqf"; + }; + class itc_land_g105ill_chg1: itc_land_g105ill { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g105ill_chg2: itc_land_g105ill { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g105ill_chg3: itc_land_g105ill { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g105ill_chg4: itc_land_g105ill { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g105ill_chg5: itc_land_g105ill { initSpeed = 320; itc_land_CountInAH = 0; }; + + class : itc_land_how_mag { + author = "Toadball"; + displayName = "G105 ICM"; + ammo = "itc_land_105mm_inert"; + itc_land_submunition = "itc_land_105mm_dpicm_helper"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G105 ICM"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g105icm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -2; + itc_land_btabListFile = "itc_land_ballistics\tables\g_105\list.sqf"; + }; + class itc_land_g105icm_chg1: itc_land_g105icm { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g105icm_chg2: itc_land_g105icm { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g105icm_chg3: itc_land_g105icm { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g105icm_chg4: itc_land_g105icm { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g105icm_chg5: itc_land_g105icm { initSpeed = 400; itc_land_CountInAH = 0; }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_122mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_122mm.hpp new file mode 100644 index 0000000..3be7bb6 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_122mm.hpp @@ -0,0 +1,79 @@ + class itc_land_g122hex: itc_land_g155hex { + author = "Toadball"; + displayName = "g122 HE"; + displayNameShort = "G122 HE"; + ammo = "itc_land_122mm"; + itc_land_submunition = "itc_land_122mm_helper"; + itc_land_charge_format = "itc_land_g122hex_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_122\list.sqf"; + }; + class itc_land_g122hex_chg1: itc_land_g122hex { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g122hex_chg2: itc_land_g122hex { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g122hex_chg3: itc_land_g122hex { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g122hex_chg4: itc_land_g122hex { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g122hex_chg5: itc_land_g122hex { initSpeed = 400; itc_land_CountInAH = 0; }; + + class itc_land_g122smo: itc_land_g155smo { + author = "Toadball"; + displayName = "g122 SMOKE"; + displayNameShort = "g122 SMOKE"; + itc_land_submunition = "itc_land_122mm_smoke"; + ammo = "itc_land_122mm_inert"; + itc_land_charge_format = "itc_land_g122smo_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_122\list.sqf"; + }; + class itc_land_g122smo_chg1: itc_land_g122smo { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g122smo_chg2: itc_land_g122smo { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g122smo_chg3: itc_land_g122smo { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g122smo_chg4: itc_land_g122smo { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g122smo_chg5: itc_land_g122smo { initSpeed = 400; itc_land_CountInAH = 0; }; + + class itc_land_g122lgm: itc_land_g155lgm { + author = "Toadball"; + displayName = "G122 LASER GUIDED"; + displayNameShort = "G122 LGM"; + ammo = "itc_land_122mm"; + itc_land_charge_format = "itc_land_g122lgm_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_122\list.sqf"; + }; + class itc_land_g122lgm_chg1: itc_land_g122lgm { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g122lgm_chg2: itc_land_g122lgm { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g122lgm_chg3: itc_land_g122lgm { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g122lgm_chg4: itc_land_g122lgm { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g122lgm_chg5: itc_land_g122lgm { initSpeed = 400; itc_land_CountInAH = 0; }; + + class itc_land_g122ill: itc_land_g155ill { + author = "Toadball"; + displayName = "G122 ILLUM"; + displayNameShort = "G122 ILLUM"; + itc_land_submunition = "itc_land_122mm_illum"; + ammo = "itc_land_122mm_inert"; + itc_land_charge_format = "itc_land_g122ill_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_122\list.sqf"; + }; + class itc_land_g122ill_chg1: itc_land_g122ill { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g122ill_chg2: itc_land_g122ill { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g122ill_chg3: itc_land_g122ill { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g122ill_chg4: itc_land_g122ill { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g122ill_chg5: itc_land_g122ill { initSpeed = 400; itc_land_CountInAH = 0; }; + + + class itc_land_g122icm: itc_land_how_mag { + author = "Toadball"; + displayName = "G122 ICM"; + ammo = "itc_land_122mm_inert"; + itc_land_submunition = "itc_land_122mm_dpicm_helper"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G122 ICM"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g122icm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -2; + itc_land_btabListFile = "itc_land_ballistics\tables\g_122\list.sqf"; + }; + class itc_land_g122icm_chg1: itc_land_g122icm { initSpeed = 86; itc_land_CountInAH = 0; }; + class itc_land_g122icm_chg2: itc_land_g122icm { initSpeed = 160; itc_land_CountInAH = 0; }; + class itc_land_g122icm_chg3: itc_land_g122icm { initSpeed = 240; itc_land_CountInAH = 0; }; + class itc_land_g122icm_chg4: itc_land_g122icm { initSpeed = 320; itc_land_CountInAH = 0; }; + class itc_land_g122icm_chg5: itc_land_g122icm { initSpeed = 400; itc_land_CountInAH = 0; }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_127mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_127mm.hpp new file mode 100644 index 0000000..7c692d0 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_127mm.hpp @@ -0,0 +1,77 @@ + class itc_land_g127hex: itc_land_g155hex { + author = "Toadball"; + displayName = "G127 HE"; + muzzleImpulseFactor[] = {1e-006,1e-006}; + displayNameShort = "G127 HE"; + ammo = "itc_land_127mm"; + itc_land_submunition = "itc_land_127mm_helper"; + itc_land_charge_format = "itc_land_g127hex_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_127\list.sqf"; + }; + class itc_land_g127hex_chg1: itc_land_g127hex { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g127hex_chg2: itc_land_g127hex { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g127hex_chg3: itc_land_g127hex { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g127hex_chg4: itc_land_g127hex { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g127hex_chg5: itc_land_g127hex { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g127smo: itc_land_g155smo { + author = "Toadball"; + displayName = "G127 SMOKE"; + muzzleImpulseFactor[] = {1e-006,1e-006}; + displayNameShort = "G127 SMOKE"; + ammo = "itc_land_127mm_inert"; + itc_land_submunition = "itc_land_127mm_smoke"; + itc_land_charge_format = "itc_land_g127smo_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_127\list.sqf"; + }; + class itc_land_g127smo_chg1: itc_land_g127smo { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g127smo_chg2: itc_land_g127smo { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g127smo_chg3: itc_land_g127smo { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g127smo_chg4: itc_land_g127smo { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g127smo_chg5: itc_land_g127smo { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g127pgm: itc_land_g155pgm { + author = "Toadball"; + displayName = "G127 GPS GUIDED"; + muzzleImpulseFactor[] = {1e-006,1e-006}; + displayNameShort = "G127 PGM"; + ammo = "itc_land_127mm"; + itc_land_charge_format = "itc_land_g127pgm_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_127\list.sqf"; + }; + class itc_land_g127pgm_chg1: itc_land_g127pgm { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g127pgm_chg2: itc_land_g127pgm { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g127pgm_chg3: itc_land_g127pgm { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g127pgm_chg4: itc_land_g127pgm { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g127pgm_chg5: itc_land_g127pgm { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g127lgm: itc_land_g155lgm { + author = "Toadball"; + displayName = "G127 LASER GUIDED"; + muzzleImpulseFactor[] = {1e-006,1e-006}; + displayNameShort = "G127 LGM"; + ammo = "itc_land_127mm"; + itc_land_charge_format = "itc_land_g127lgm_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_127\list.sqf"; + }; + class itc_land_g127lgm_chg1: itc_land_g127lgm { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g127lgm_chg2: itc_land_g127lgm { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g127lgm_chg3: itc_land_g127lgm { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g127lgm_chg4: itc_land_g127lgm { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g127lgm_chg5: itc_land_g127lgm { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g127ill: itc_land_g155ill { + author = "Toadball"; + displayName = "G127 ILLUM"; + muzzleImpulseFactor[] = {1e-006,1e-006}; + displayNameShort = "G127 ILLUM"; + ammo = "itc_land_127mm_inert"; + itc_land_submunition = "itc_land_127mm_illum"; + itc_land_charge_format = "itc_land_g127ill_chg%1"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_127\list.sqf"; + }; + class itc_land_g127ill_chg1: itc_land_g127ill { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g127ill_chg2: itc_land_g127ill { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g127ill_chg3: itc_land_g127ill { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g127ill_chg4: itc_land_g127ill { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g127ill_chg5: itc_land_g127ill { initSpeed = 500; itc_land_CountInAH = 0; }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_152mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_152mm.hpp new file mode 100644 index 0000000..ca75a85 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_152mm.hpp @@ -0,0 +1,158 @@ + class itc_land_g152hex: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 HE"; + ammo = "itc_land_155mm"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 HE"; + itc_land_fuze = "mof35_mod0"; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g152hex_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152hex_chg1: itc_land_g152hex { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152hex_chg2: itc_land_g152hex { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152hex_chg3: itc_land_g152hex { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152hex_chg4: itc_land_g152hex { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152hex_chg5: itc_land_g152hex { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152smo: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 SMOKE"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 SMOKE"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g152smo_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_submunition = "itc_land_155mm_smoke"; + itc_land_timeModifier = -1.5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152smo_chg1: itc_land_g152smo { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152smo_chg2: itc_land_g152smo { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152smo_chg3: itc_land_g152smo { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152smo_chg4: itc_land_g152smo { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152smo_chg5: itc_land_g152smo { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152icm: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 ICM"; + ammo = "itc_land_155mm_inert"; + itc_land_submunition = "itc_land_155mm_dpicm_helper"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 ICM"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g152icm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -2; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152icm_chg1: itc_land_g152icm { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152icm_chg2: itc_land_g152icm { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152icm_chg3: itc_land_g152icm { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152icm_chg4: itc_land_g152icm { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152icm_chg5: itc_land_g152icm { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152mat: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 MINE-AT"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 MAT"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g152mat_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -1.2; + itc_land_submunition = "itc_land_155mm_fascam_at_helper"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152mat_chg1: itc_land_g152mat { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152mat_chg2: itc_land_g152mat { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152mat_chg3: itc_land_g152mat { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152mat_chg4: itc_land_g152mat { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152mat_chg5: itc_land_g152mat { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152map: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 MINE-AP"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 MAP"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g152map_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -1.2; + itc_land_submunition = "itc_land_155mm_fascam_ap_helper"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152map_chg1: itc_land_g152map { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152map_chg2: itc_land_g152map { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152map_chg3: itc_land_g152map { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152map_chg4: itc_land_g152map { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152map_chg5: itc_land_g152map { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152pgm: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 GPS GUIDED"; + ammo = "Sh_155mm_AMOS"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 PGM"; + itc_land_fuze = "mof35_mod2"; + itc_land_guidance[] = {"gps_inertial","itc_land_guidance_fnc_pgm15x"}; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g152pgm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152pgm_chg1: itc_land_g152pgm { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152pgm_chg2: itc_land_g152pgm { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152pgm_chg3: itc_land_g152pgm { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152pgm_chg4: itc_land_g152pgm { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152pgm_chg5: itc_land_g152pgm { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152lgm: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 LASER GUIDED"; + ammo = "Sh_155mm_AMOS"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 LGM"; + itc_land_fuze = "mof35_mod2"; + itc_land_guidance[] = {"laser_coded","itc_land_guidance_fnc_lgm15x"}; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g152lgm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152lgm_chg1: itc_land_g152lgm { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152lgm_chg2: itc_land_g152lgm { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152lgm_chg3: itc_land_g152lgm { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152lgm_chg4: itc_land_g152lgm { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152lgm_chg5: itc_land_g152lgm { initSpeed = 515; itc_land_CountInAH = 0; }; + + class itc_land_g152ill: itc_land_how_mag { + author = "Toadball"; + displayName = "G152 ILLUM"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G152 ILLUM"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g152ill_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_submunition = "itc_land_155mm_illum"; + itc_land_heightModifier = 200; + itc_land_btabListFile = "itc_land_ballistics\tables\g_152\list.sqf"; + }; + class itc_land_g152ill_chg1: itc_land_g152ill { initSpeed = 103; itc_land_CountInAH = 0; }; + class itc_land_g152ill_chg2: itc_land_g152ill { initSpeed = 206; itc_land_CountInAH = 0; }; + class itc_land_g152ill_chg3: itc_land_g152ill { initSpeed = 309; itc_land_CountInAH = 0; }; + class itc_land_g152ill_chg4: itc_land_g152ill { initSpeed = 412; itc_land_CountInAH = 0; }; + class itc_land_g152ill_chg5: itc_land_g152ill { initSpeed = 515; itc_land_CountInAH = 0; }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_155mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_155mm.hpp new file mode 100644 index 0000000..9b68391 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_155mm.hpp @@ -0,0 +1,208 @@ + class itc_land_g155hex: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 HE"; + ammo = "itc_land_155mm"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 HE"; + itc_land_fuze = "mof35_mod0"; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g155hex_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155hex_chg1: itc_land_g155hex { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155hex_chg2: itc_land_g155hex { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155hex_chg3: itc_land_g155hex { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155hex_chg4: itc_land_g155hex { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155hex_chg5: itc_land_g155hex { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155smo: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 SMOKE"; + //ammo = "itc_land_155mm_inert"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 SMOKE"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g155smo_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_submunition = "itc_land_155mm_smoke"; + itc_land_timeModifier = -1.5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155smo_chg1: itc_land_g155smo { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155smo_chg2: itc_land_g155smo { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155smo_chg3: itc_land_g155smo { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155smo_chg4: itc_land_g155smo { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155smo_chg5: itc_land_g155smo { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155icm: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 ICM"; + ammo = "itc_land_155mm_inert"; + itc_land_submunition = "itc_land_155mm_dpicm_helper"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 ICM"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g155icm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -2; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155icm_chg1: itc_land_g155icm { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155icm_chg2: itc_land_g155icm { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155icm_chg3: itc_land_g155icm { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155icm_chg4: itc_land_g155icm { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155icm_chg5: itc_land_g155icm { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155mat: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 MINE-AT"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 MAT"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g155mat_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -1.2; + itc_land_submunition = "itc_land_155mm_fascam_at_helper"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155mat_chg1: itc_land_g155mat { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155mat_chg2: itc_land_g155mat { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155mat_chg3: itc_land_g155mat { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155mat_chg4: itc_land_g155mat { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155mat_chg5: itc_land_g155mat { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155map: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 MINE-AP"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 MAP"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g155map_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_timeModifier = -1.5; + itc_land_submunition = "itc_land_155mm_fascam_ap_helper"; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155map_chg1: itc_land_g155map { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155map_chg2: itc_land_g155map { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155map_chg3: itc_land_g155map { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155map_chg4: itc_land_g155map { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155map_chg5: itc_land_g155map { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155pgm: itc_land_how_mag { + author = "Toadball"; + initSpeed = 162; + displayName = "G155 GPS GUIDED"; + ammo = "itc_land_155mm"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 PGM"; + itc_land_fuze = "mof35_mod2"; + itc_land_guidance[] = {"gps_inertial","itc_land_guidance_fnc_pgm15x"}; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g155pgm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155pgm_chg1: itc_land_g155pgm { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155pgm_chg2: itc_land_g155pgm { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155pgm_chg3: itc_land_g155pgm { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155pgm_chg4: itc_land_g155pgm { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155pgm_chg5: itc_land_g155pgm { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155lgm: itc_land_how_mag { + author = "Toadball"; + displayName = "G155 LASER GUIDED"; + ammo = "itc_land_155mm"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 LGM"; + itc_land_fuze = "mof35_mod2"; + itc_land_guidance[] = {"laser_coded","itc_land_guidance_fnc_lgm15x"}; + itc_land_submunition = "itc_land_155mm_helper"; + itc_land_charge_format = "itc_land_g155lgm_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155lgm_chg1: itc_land_g155lgm { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155lgm_chg2: itc_land_g155lgm { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155lgm_chg3: itc_land_g155lgm { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155lgm_chg4: itc_land_g155lgm { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155lgm_chg5: itc_land_g155lgm { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155ill: itc_land_how_mag { + author = "Toadball"; + initSpeed = 162; + displayName = "G155 ILLUM"; + ammo = "itc_land_155mm_inert"; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 ILLUM"; + itc_land_submunition = "itc_land_155mm_illum"; + itc_land_fuze = "mof35_mod1"; + itc_land_charge_format = "itc_land_g155ill_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_heightModifier = 200; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155ill_chg1: itc_land_g155ill { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155ill_chg2: itc_land_g155ill { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155ill_chg3: itc_land_g155ill { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155ill_chg4: itc_land_g155ill { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155ill_chg5: itc_land_g155ill { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155ext: itc_land_how_mag { + author = "Yax"; + initSpeed = 162; + displayName = "G155 EXTRA"; + ammo = "itc_land_155mm_inert"; + itc_land_submunitionCount = 2; + itc_land_submunitionScript = "itc_land_veh_weapons_fnc_deployExtra"; + itc_land_heightModifier = 50; + itc_land_timeModifier = -5; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 EXTRA"; + itc_land_fuze = "mof35_mod3"; + itc_land_charge_format = "itc_land_g155ext_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155ext_chg1: itc_land_g155ext { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155ext_chg2: itc_land_g155ext { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155ext_chg3: itc_land_g155ext { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155ext_chg4: itc_land_g155ext { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155ext_chg5: itc_land_g155ext { initSpeed = 500; itc_land_CountInAH = 0; }; + + class itc_land_g155falat: itc_land_how_mag { + author = "Yax"; + initSpeed = 162; + displayName = "G155 FALAT"; + ammo = "itc_land_155mm_inert"; + itc_land_submunitionCount = 2; + itc_land_submunitionScript = "itc_land_veh_weapons_fnc_deployFalat"; + itc_land_guidance[] = {"laser_coded_2"}; + itc_land_heightModifier = 50; + itc_land_timeModifier = -5; + muzzleImpulseFactor[] = {15, 30}; + displayNameShort = "G155 FALAT"; + itc_land_fuze = "mof35_mod3"; + itc_land_charge_format = "itc_land_g155falat_chg%1"; + itc_land_CountInAH = 1; + itc_land_maxChargeIndex = 5; + itc_land_btabListFile = "itc_land_ballistics\tables\g_155\list.sqf"; + }; + class itc_land_g155falat_chg1: itc_land_g155falat { initSpeed = 100; itc_land_CountInAH = 0; }; + class itc_land_g155falat_chg2: itc_land_g155falat { initSpeed = 200; itc_land_CountInAH = 0; }; + class itc_land_g155falat_chg3: itc_land_g155falat { initSpeed = 300; itc_land_CountInAH = 0; }; + class itc_land_g155falat_chg4: itc_land_g155falat { initSpeed = 400; itc_land_CountInAH = 0; }; + class itc_land_g155falat_chg5: itc_land_g155falat { initSpeed = 500; itc_land_CountInAH = 0; }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgMagazines_230mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_230mm.hpp new file mode 100644 index 0000000..fcfdd88 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgMagazines_230mm.hpp @@ -0,0 +1,55 @@ +class 12Rnd_230mm_rockets; +class itc_land_m230hex_12rnd : 12Rnd_230mm_rockets { + author = "Yax"; + initSpeed = 600; + ammo = "itc_land_230mm_he"; + displayName = "M230 HE"; + displayNameShort = "M230 HE"; + itc_land_fuze = "mof35_mod2"; + itc_land_submunition = "itc_land_230mm_helper"; + itc_land_btabListFile = "itc_land_ballistics\tables\b_230\list.sqf"; +}; +class itc_land_m230pgm_12rnd : itc_land_m230hex_12rnd { + itc_land_guidance[] = {"gps_inertial","itc_land_guidance_fnc_pgm230"}; + displayName = "M230 PGM"; + displayNameShort = "M230 PGM"; +}; +class itc_land_m230pgm_6rnd : itc_land_m230pgm_12rnd { + count = 6; +}; +class itc_land_m230icm_12rnd : itc_land_m230hex_12rnd { + author = "Toadball"; + ammo = "itc_land_230mm_inert"; + displayName = "M230 ICM"; + displayNameShort = "M230 ICM"; + itc_land_fuze = "mof35_mod1"; + itc_land_submunition = "itc_land_230mm_icm_helper"; +}; +class itc_land_m230icm_6rnd : itc_land_m230icm_12rnd { + count = 6; +}; +class itc_land_m230gicm_12rnd : itc_land_m230icm_12rnd { + displayName = "M230 G-ICM"; + displayNameShort = "M230 G-ICM"; + itc_land_guidance[] = {"gps_inertial","itc_land_guidance_fnc_pgm230"}; +}; +class itc_land_m230gicm_6rnd : itc_land_m230gicm_12rnd { + count = 6; +}; +class itc_land_m230mat_12rnd : itc_land_m230hex_12rnd { + author = "Toadball"; + ammo = "itc_land_230mm_inert"; + displayName = "M230 MINE-AT"; + displayNameShort = "M230 MAT"; + itc_land_fuze = "mof35_mod1"; + itc_land_submunition = "itc_land_230mm_fascam_at_helper"; +}; +class itc_land_m230map_12rnd : itc_land_m230hex_12rnd { + author = "Toadball"; + ammo = "itc_land_230mm_inert"; + displayName = "M230 MINE-AP"; + displayNameShort = "M230 MAP"; + itc_land_fuze = "mof35_mod1"; + itc_land_submunition = "itc_land_230mm_fascam_ap_helper"; +}; + diff --git a/addons/ITCExpansionGuidanceFuzes/CfgVehicles.hpp b/addons/ITCExpansionGuidanceFuzes/CfgVehicles.hpp new file mode 100644 index 0000000..5062eeb --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgVehicles.hpp @@ -0,0 +1,42 @@ +class CfgVehicles { + class Parachute_02_base_F; + class ITC_155Extra: Parachute_02_base_F { + castDriverShadow = 0; + destrType = "DestructDefault"; + displayName = "155Extra"; + model = "\z\ace\addons\huntir\data\huntir.p3d"; + scope = 1; + class HitPoints { + class HitEngine { + armor = 0; + material = -1; + name = ""; + visual = ""; + radius = 0; + passThrough = 0; + explosionShielding = 0; + }; + class HitParachute { + armor = 0.0001; + material = -1; + name = "parachute"; + visual = ""; + radius = 0.2; + passThrough = 1; + explosionShielding = 0; + }; + class HitCamera { + armor = 0.001; + material = -1; + name = "camera"; + visual = ""; + radius = 0.025; + passThrough = 1; + explosionShielding = 1; + }; + }; + }; + class ITC_155Falat: ITC_155Extra { + displayName = "155Falat"; + }; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons.hpp new file mode 100644 index 0000000..07ac438 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons.hpp @@ -0,0 +1,4 @@ +class CfgWeapons { + #include "CfgWeapons_mlrs.hpp" + #include "CfgWeapons_howitzers.hpp" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers.hpp new file mode 100644 index 0000000..d659263 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers.hpp @@ -0,0 +1,64 @@ + class CannonCore; + class mortar_155mm_AMOS: CannonCore { class Single1; }; + class itc_land_howitzer_base: mortar_155mm_AMOS { + scope = 0; + displayName = "Howitzer 155 mm"; + autoReload = 0; + modes[] = {"Single"}; + reloadTime = 1; + magazineReloadTime = 5; + magazines[] = {}; + class Single: Single1 { + displayName = ""; + artilleryCharge = 1; + reloadTime = 5; + }; + class EventHandlers + { + class itc_land_veh_weapons + { + fired = "_this call itc_land_veh_weapons_fnc_fired;"; + }; + }; + }; + + class itc_land_155mm_howitzer: itc_land_howitzer_base { + scope = 1; + #include "CfgWeapons_howitzers_magazines155mm.hpp" + displayName = "H155 L/52"; + }; + class itc_land_152mm_howitzer: itc_land_howitzer_base { + scope = 1; + #include "CfgWeapons_howitzers_magazines152mm.hpp" + displayName = "H152 L/52"; + }; + class itc_land_105mm_howitzer: itc_land_howitzer_base { + scope = 1; + #include "CfgWeapons_howitzers_magazines105mm.hpp" + displayName = "H105 L/30"; + class Single: Single1 { + displayName = ""; + artilleryCharge = 1; + reloadTime = 3; + }; + }; + class itc_land_122mm_howitzer: itc_land_howitzer_base { + scope = 1; + #include "CfgWeapons_howitzers_magazines122mm.hpp" + displayName = "H122 L/38"; + class Single: Single1 { + displayName = ""; + artilleryCharge = 1; + reloadTime = 3; + }; + }; + class itc_land_127mm_navalgunsystem: itc_land_howitzer_base { + scope = 1; + #include "CfgWeapons_howitzers_magazines127mm.hpp" + displayName = "NG127 L/54"; + class Single: Single1 { + displayName = ""; + artilleryCharge = 1; + reloadTime = 3; + }; + }; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines105mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines105mm.hpp new file mode 100644 index 0000000..44f8808 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines105mm.hpp @@ -0,0 +1,27 @@ +//CfgWeapons_Magazines.hpp + +magazines[] = { + "itc_land_g105hex_chg1", + "itc_land_g105hex_chg2", + "itc_land_g105hex_chg3", + "itc_land_g105hex_chg4", + "itc_land_g105hex_chg5", + + "itc_land_g105smo_chg1", + "itc_land_g105smo_chg2", + "itc_land_g105smo_chg3", + "itc_land_g105smo_chg4", + "itc_land_g105smo_chg5", + + "itc_land_g105icm_chg1", + "itc_land_g105icm_chg2", + "itc_land_g105icm_chg3", + "itc_land_g105icm_chg4", + "itc_land_g105icm_chg5", + + "itc_land_g105ill_chg1", + "itc_land_g105ill_chg2", + "itc_land_g105ill_chg3", + "itc_land_g105ill_chg4", + "itc_land_g105ill_chg5" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines122mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines122mm.hpp new file mode 100644 index 0000000..f176064 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines122mm.hpp @@ -0,0 +1,33 @@ +//CfgWeapons_Magazines.hpp + +magazines[] = { + "itc_land_g122hex_chg1", + "itc_land_g122hex_chg2", + "itc_land_g122hex_chg3", + "itc_land_g122hex_chg4", + "itc_land_g122hex_chg5", + + "itc_land_g122smo_chg1", + "itc_land_g122smo_chg2", + "itc_land_g122smo_chg3", + "itc_land_g122smo_chg4", + "itc_land_g122smo_chg5", + + "itc_land_g122icm_chg1", + "itc_land_g122icm_chg2", + "itc_land_g122icm_chg3", + "itc_land_g122icm_chg4", + "itc_land_g122icm_chg5", + + "itc_land_g122ill_chg1", + "itc_land_g122ill_chg2", + "itc_land_g122ill_chg3", + "itc_land_g122ill_chg4", + "itc_land_g122ill_chg5", + + "itc_land_g122lgm_chg1", + "itc_land_g122lgm_chg2", + "itc_land_g122lgm_chg3", + "itc_land_g122lgm_chg4", + "itc_land_g122lgm_chg5" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines127mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines127mm.hpp new file mode 100644 index 0000000..b466f2d --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines127mm.hpp @@ -0,0 +1,33 @@ +//CfgWeapons_Magazines.hpp + +magazines[] = { + "itc_land_g127hex_chg1", + "itc_land_g127hex_chg2", + "itc_land_g127hex_chg3", + "itc_land_g127hex_chg4", + "itc_land_g127hex_chg5", + + "itc_land_g127smo_chg1", + "itc_land_g127smo_chg2", + "itc_land_g127smo_chg3", + "itc_land_g127smo_chg4", + "itc_land_g127smo_chg5", + + "itc_land_g127pgm_chg1", + "itc_land_g127pgm_chg2", + "itc_land_g127pgm_chg3", + "itc_land_g127pgm_chg4", + "itc_land_g127pgm_chg5", + + "itc_land_g127lgm_chg1", + "itc_land_g127lgm_chg2", + "itc_land_g127lgm_chg3", + "itc_land_g127lgm_chg4", + "itc_land_g127lgm_chg5", + + "itc_land_g127ill_chg1", + "itc_land_g127ill_chg2", + "itc_land_g127ill_chg3", + "itc_land_g127ill_chg4", + "itc_land_g127ill_chg5" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines152mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines152mm.hpp new file mode 100644 index 0000000..bad69f0 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines152mm.hpp @@ -0,0 +1,52 @@ +//CfgWeapons_Magazines.hpp + +magazines[] = { + "itc_land_g152hex_chg1", + "itc_land_g152hex_chg2", + "itc_land_g152hex_chg3", + "itc_land_g152hex_chg4", + "itc_land_g152hex_chg5", + + "itc_land_g152smo_chg1", + "itc_land_g152smo_chg2", + "itc_land_g152smo_chg3", + "itc_land_g152smo_chg4", + "itc_land_g152smo_chg5", + + "itc_land_g152icm_chg1", + "itc_land_g152icm_chg2", + "itc_land_g152icm_chg3", + "itc_land_g152icm_chg4", + "itc_land_g152icm_chg5", + + "itc_land_g152mat_chg1", + "itc_land_g152mat_chg2", + "itc_land_g152mat_chg3", + "itc_land_g152mat_chg4", + "itc_land_g152mat_chg5", + + "itc_land_g152map_chg1", + "itc_land_g152map_chg2", + "itc_land_g152map_chg3", + "itc_land_g152map_chg4", + "itc_land_g152map_chg5", + + "itc_land_g152pgm_chg1", + "itc_land_g152pgm_chg2", + "itc_land_g152pgm_chg3", + "itc_land_g152pgm_chg4", + "itc_land_g152pgm_chg5", + + "itc_land_g152lgm_chg1", + "itc_land_g152lgm_chg2", + "itc_land_g152lgm_chg3", + "itc_land_g152lgm_chg4", + "itc_land_g152lgm_chg5", + + "itc_land_g152ill_chg1", + "itc_land_g152ill_chg2", + "itc_land_g152ill_chg3", + "itc_land_g152ill_chg4", + "itc_land_g152ill_chg5" +}; + \ No newline at end of file diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines155mm.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines155mm.hpp new file mode 100644 index 0000000..a8d4597 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_howitzers_magazines155mm.hpp @@ -0,0 +1,63 @@ +//CfgWeapons_Magazines.hpp + +magazines[] = { + "itc_land_g155hex_chg1", + "itc_land_g155hex_chg2", + "itc_land_g155hex_chg3", + "itc_land_g155hex_chg4", + "itc_land_g155hex_chg5", + + "itc_land_g155smo_chg1", + "itc_land_g155smo_chg2", + "itc_land_g155smo_chg3", + "itc_land_g155smo_chg4", + "itc_land_g155smo_chg5", + + "itc_land_g155icm_chg1", + "itc_land_g155icm_chg2", + "itc_land_g155icm_chg3", + "itc_land_g155icm_chg4", + "itc_land_g155icm_chg5", + + "itc_land_g155mat_chg1", + "itc_land_g155mat_chg2", + "itc_land_g155mat_chg3", + "itc_land_g155mat_chg4", + "itc_land_g155mat_chg5", + + "itc_land_g155map_chg1", + "itc_land_g155map_chg2", + "itc_land_g155map_chg3", + "itc_land_g155map_chg4", + "itc_land_g155map_chg5", + + "itc_land_g155pgm_chg1", + "itc_land_g155pgm_chg2", + "itc_land_g155pgm_chg3", + "itc_land_g155pgm_chg4", + "itc_land_g155pgm_chg5", + + "itc_land_g155lgm_chg1", + "itc_land_g155lgm_chg2", + "itc_land_g155lgm_chg3", + "itc_land_g155lgm_chg4", + "itc_land_g155lgm_chg5", + + "itc_land_g155ill_chg1", + "itc_land_g155ill_chg2", + "itc_land_g155ill_chg3", + "itc_land_g155ill_chg4", + "itc_land_g155ill_chg5", + + "itc_land_g155ext_chg1", + "itc_land_g155ext_chg2", + "itc_land_g155ext_chg3", + "itc_land_g155ext_chg4", + "itc_land_g155ext_chg5", + + "itc_land_g155falat_chg1", + "itc_land_g155falat_chg2", + "itc_land_g155falat_chg3", + "itc_land_g155falat_chg4", + "itc_land_g155falat_chg5" +}; diff --git a/addons/ITCExpansionGuidanceFuzes/CfgWeapons_mlrs.hpp b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_mlrs.hpp new file mode 100644 index 0000000..ba5befc --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/CfgWeapons_mlrs.hpp @@ -0,0 +1,29 @@ +class RocketPods; +class rockets_230mm_GAT : RocketPods { + class Mode_16; +}; +class itc_land_230mm_mlrs : rockets_230mm_GAT { + modes[] = {"Mode_16"}; + displayName = "M230 MLRS"; + magazineReloadTime = 30; + magazines[] = { + "itc_land_m230hex_12rnd", + "itc_land_m230pgm_12rnd","itc_land_m230pgm_6rnd", + "itc_land_m230icm_12rnd","itc_land_m230icm_6rnd", + "itc_land_m230gicm_12rnd","itc_land_m230gicm_6rnd", + "itc_land_m230mat_12rnd","itc_land_m230map_12rnd" + }; + class Mode_16 : Mode_16 { + displayName = "MLRS"; + artilleryCharge = 1; + reloadTime = 0.5; + + }; + class EventHandlers + { + class itc_land_veh_weapons + { + fired = "_this call itc_land_veh_weapons_fnc_fired;"; + }; + }; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/ITC_Land_CfgFuzes.hpp b/addons/ITCExpansionGuidanceFuzes/ITC_Land_CfgFuzes.hpp new file mode 100644 index 0000000..3d22390 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/ITC_Land_CfgFuzes.hpp @@ -0,0 +1,42 @@ +class ITC_Land_CfgFuzes { + + class ph_fuze { + modes[] = {"prox","pd","time","delay"}; + modeDesc[] = {"Proximity","Point Detonate","Time","Delay"}; + firedEvent = "ph_fuzeFunc"; + }; + //Modular Fuse 35: Mod 0 All modes, subsequent numbers are more specific + class mof35_mod0 { + modes[] = {"pd","prox","time","delay"}; + modeDesc[] = {"Point Detonate","Proximity","Time","Delay"}; + firedEvent = "itc_land_veh_weapons_fnc_firedMof35"; + proxHOB = 9; + }; + class mof35_mod1: mof35_mod0 { + modes[] = {"time"}; + modeDesc[] = {"Time"}; + firedEvent = "itc_land_veh_weapons_fnc_firedMof35"; + }; + class mof35_mod2: mof35_mod0 { + modes[] = {"pd","prox","delay"}; + modeDesc[] = {"Point Detonate","Proximity","Delay"}; + firedEvent = "itc_land_veh_weapons_fnc_firedMof35"; + }; + class mof35_mod3: mof35_mod0 { //FOR CARGO SHELLS LIKE EXTRA + modes[] = {"time"}; + modeDesc[] = {"Time"}; + firedEvent = "itc_land_veh_weapons_fnc_firedMof35Mod3"; + }; + class mof35_mod4: mof35_mod0 { //FOR CARGO SHELLS LIKE EXTRA + modes[] = {"pd"}; + modeDesc[] = {"pd"}; + firedEvent = "itc_land_veh_weapons_fnc_firedMof35"; + }; + class sam35_mod0 { //FOR SAMS WITH PROX FUZING + modes[] = {"prox"}; + modeDesc[] = {"Proximity"}; + firedEvent = "itc_land_veh_weapons_fnc_firedSAM35"; + proxFOV = 60; + proxRAN = 30; + }; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/config.cpp b/addons/ITCExpansionGuidanceFuzes/config.cpp new file mode 100644 index 0000000..8e7a819 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/config.cpp @@ -0,0 +1,24 @@ +class CfgPatches { + class itc_land_veh_weapons { + author = "ITC Addons Team"; + authors[] = {"ToadBall","Yax","VKing"}; + requiredaddons[] = {"A3_Weapons_F","itc_land_veh_weapons"}; + requiredversion = 1.8; + units[] = {}; + weapons[] = { + "itc_land_155mm_howitzer", + "itc_land_152mm_howitzer" + }; + magazines[] = { + }; + }; +}; + +class mode_semiauto; + +#include "ITC_Land_CfgFuzes.hpp" +#include "CfgFunctions.hpp" +#include "CfgAmmo.hpp" +#include "CfgWeapons.hpp" +#include "CfgMagazines.hpp" +#include "CfgVehicles.hpp" diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_adjustMuzzleVelG15x.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_adjustMuzzleVelG15x.sqf new file mode 100644 index 0000000..fced507 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_adjustMuzzleVelG15x.sqf @@ -0,0 +1,8 @@ +params ["_vehicle","_weapon","_muzzle","_mode","_ammo","_magazine","_projectile"]; + +private _currentSpeed = vectorMagnitude (velocity _projectile); +private _randomFactor = random [(_currentSpeed / 100) * -0.5,0,(_currentSpeed / 100) * 0.5]; +private _targetSpeed = _currentSpeed + _randomFactor; +private _targetVelocity = (vectorNormalized velocity _projectile) vectorMultiply _targetSpeed; +_projectile setVelocity _targetVelocity; +//player sideChat format["Adjusting velocity from %1 to %2", _currentSpeed, _targetSpeed]; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_deployExtra.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_deployExtra.sqf new file mode 100644 index 0000000..ebf4487 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_deployExtra.sqf @@ -0,0 +1,58 @@ +params ["_subMunitionIndex", "_position", "_velocity", "_pitch", "_bank"]; +//player sideChat format ["%1 deployed", _subMunitionIndex]; +_spawnPosAdjustment = (vectorNormalized _velocity) vectorMultiply _subMunitionIndex; +_extra = createVehicle ["Land_FoodContainer_01_F", _position vectorAdd _spawnPosAdjustment, [], 0, "FLY"]; +//_extra = createVehicle ["Land_FoodContainer_01_F", _position, [], 0, "FLY"]; +_randomizedVelocity = _velocity vectorAdd [random 3, random 3, random 3]; +_extra setVelocity _randomizedVelocity; + +[{ + params ["_pfhValues","_pfhId"]; + _pfhValues params ["_projectile", "_firedTime", "_initialSpeed"]; + //INITIAL DEPLOYMENT FLIGHT + if(time > _firedTime + 4 && typeOf _projectile == "Land_FoodContainer_01_F") then { //OPEN THE PARACHUTE + //systemChat "PARACHUTE DEPLOYED"; + _extra = createVehicle ["ITC_155Extra", getPos _projectile, [], 0, "FLY"]; + _extra setVelocity (velocity _projectile); + deleteVehicle _projectile; + _projectile = _extra; + _pfhValues set [0, _extra]; + }; + + if(time > _firedTime + 8 && typeOf _projectile == "ITC_155Extra") then { //SEARCH FOR A TARGET + _tanks = nearestObjects [[getPos _projectile # 0, getPos _projectile # 1, 0], ["Wheeled_APC_F","Tank_F"], 200]; + //systemChat str _tanks; + + _selectTankIndex = _tanks findIf {(alive _x && _x distance _projectile < 120)}; + //systemChat str _selectTankIndex; + + if(_selectTankIndex != -1) then { + _selectTank = _tanks # _selectTankIndex; + + // systemChat format ["TARGET FOUND: %1",_selectTank]; + + _heat = createVehicle ["R_MRAAWS_HEAT_F", getPos _projectile, [], 0, "FLY"]; + [_heat, -90, 0] call BIS_fnc_setPitchBank; + _vectorToTank = (getPos _projectile) vectorFromTo ((getPos _selectTank) vectorAdd [0,0,1]); + _heat setVelocity (_vectorToTank vectorMultiply 5000); + + //systemChat str _vectorToTank; + + deleteVehicle _projectile; + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; + }; + + if(getPosATL _projectile # 2 < 20 || getPosASL _projectile # 2 < 15) exitWith { + //systemChat "SELF DESTRUCT"; + _heat = createVehicle ["R_MRAAWS_HEAT_F", (getPos _projectile) vectorAdd [0,0,10], [], 0, "FLY"]; + [_heat, -90, 0] call BIS_fnc_setPitchBank; + _heat setVelocity [0,0,-50]; + deleteVehicle _projectile; + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; + + if(!alive _projectile) exitWith { + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; +}, 0.5, [_extra, time, vectorNormalized _velocity]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_deployFalat.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_deployFalat.sqf new file mode 100644 index 0000000..5044377 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_deployFalat.sqf @@ -0,0 +1,51 @@ +params ["_subMunitionIndex", "_position", "_velocity", "_pitch", "_bank", "_guidanceInfo"]; + +private _laserCode = 1111; +if (_subMunitionIndex < 2) then { + _laserCode = _guidanceInfo # 0 # _subMunitionIndex; +}; + +//player sideChat format ["%1 deployed", _subMunitionIndex]; +_spawnPosAdjustment = (vectorNormalized _velocity) vectorMultiply _subMunitionIndex; +_extra = createVehicle ["Land_FoodContainer_01_F", _position vectorAdd _spawnPosAdjustment, [], 0, "FLY"]; +//_extra = createVehicle ["Land_FoodContainer_01_F", _position, [], 0, "FLY"]; +_randomizedVelocity = _velocity vectorAdd [random 5, random 5, random 5]; +_extra setVelocity _randomizedVelocity; + +[{ + params ["_pfhValues","_pfhId"]; + _pfhValues params ["_projectile", "_firedTime", "_initialSpeed", "_laserCode"]; + //INITIAL DEPLOYMENT FLIGHT + if(time > _firedTime + 4 && typeOf _projectile == "Land_FoodContainer_01_F") then { //OPEN THE PARACHUTE + //systemChat "PARACHUTE DEPLOYED"; + _extra = createVehicle ["ITC_155Extra", getPos _projectile, [], 0, "FLY"]; + _extra setVelocity (velocity _projectile); + deleteVehicle _projectile; + _projectile = _extra; + _pfhValues set [0, _extra]; + }; + + if(time > _firedTime + 8 && typeOf _projectile == "ITC_155Extra") then { //SEARCH FOR A TARGET + _spot = [getPosASL _projectile, [0,0,-1], 90, 300, [1500, 1550], _laserCode] call ace_laser_fnc_seekerFindLaserSpot; + if(!isNil{_spot select 0}) then { + _heat = createVehicle ["R_MRAAWS_HEAT_F", getPos _projectile, [], 0, "FLY"]; + [_heat, -90, 0] call BIS_fnc_setPitchBank; + _vectorToTank = (getPosASL _projectile) vectorFromTo (_spot select 0); + _heat setVelocity (_vectorToTank vectorMultiply 5000); + + deleteVehicle _projectile; + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; + }; + + if(time > _firedTime + 180 && typeOf _projectile == "ITC_155Extra") then { //SEARCH FOR A TARGET + _heat = createVehicle ["R_MRAAWS_HEAT_F", getPos _projectile, [], 0, "FLY"]; + [_heat, -90, 0] call BIS_fnc_setPitchBank; + triggerAmmo _heat; + deleteVehicle _projectile; + }; + + if(!alive _projectile) exitWith { + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; +}, 0.5, [_extra, time, vectorNormalized _velocity, _laserCode]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_fired.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_fired.sqf new file mode 100644 index 0000000..6723de7 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_fired.sqf @@ -0,0 +1,21 @@ +params ["_unit", "", "", "", "_ammo", "_magazine", "_projectile", "_gunner"]; +if (!local _gunner) exitWith {}; + +_fuze = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_fuze"); +_event = configFile >> "ITC_Land_CfgFuzes" >> _fuze >> "firedEvent"; + +if (isText _event) then { + _this call (missionNamespace getVariable [getText _event, {}]); +}; + +_dispersionEvent = configFile >> "CfgMagazines" >> _magazine >> "dispersionEvent"; +if (isText _dispersionEvent) then { + _this call (missionNamespace getVariable [getText _dispersionEvent, {}]); +}; + +_guidanceConfig = (configFile >> "CfgMagazines" >> _magazine >> "itc_land_guidance") call BIS_fnc_getCfgData; + +if (!isNil{_guidanceConfig # 1}) then { + //player sideChat format["INIT GUIDANCE %1",_guidanceConfig # 0]; + _this call (missionNamespace getVariable [_guidanceConfig # 1, {}]); +}; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35.sqf new file mode 100644 index 0000000..ff073c4 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35.sqf @@ -0,0 +1,21 @@ +/* + * Author: Yax + * Fired event for ITC Howitzers with Mof35 fuzed shells + */ +params ["_vehicle", "", "", "", "_ammo", "_magazine", "_projectile", "_gunner"]; +if (!local _gunner) exitWith {}; +_fuzeType = _vehicle getVariable ["itc_land_selectedFuzeMode","pd"]; +_fuzeValue = _vehicle getVariable ["itc_land_fuzeValues",0]; + + +if(isNil{_fuzeType}) exitWith {}; +if(_fuzeType == "" || _fuzeType == "pd") exitWith {}; + +_fuzeMethods = [ + ["delay",itc_land_veh_weapons_fnc_fuzeDelay], + ["time",itc_land_veh_weapons_fnc_fuzeTime], + ["prox",itc_land_veh_weapons_fnc_fuzeProx] +]; + +_fuzeMethod = _fuzeMethods # (_fuzeMethods findIf {(_x # 0) == _fuzeType}) # 1; +[_fuzeMethod, 0, [_projectile, _magazine, getPosATL _projectile, _fuzeType, _fuzeValue, time,[0,0,0]]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35Mod3.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35Mod3.sqf new file mode 100644 index 0000000..4328465 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedMof35Mod3.sqf @@ -0,0 +1,47 @@ +/* + * Author: Yax + * Fired event for ITC Howitzers with Mof35Mod3 fuzed shells + */ +params ["_vehicle", "", "", "", "_ammo", "_magazine", "_projectile", "_gunner"]; +if (!local _gunner) exitWith {}; + +_fuzeType = "time"; +_fuzeValue = _vehicle getVariable ["itc_land_fuzeValues",0]; +private _guidanceInfo = [ + [ + _vehicle getVariable ["itc_land_guidance_laserCode",1111], + _vehicle getVariable ["itc_land_guidance_laserCode_2",1112] + ], + _vehicle getVariable ["itc_land_guidance_targetGrid","00000000"], + _vehicle getVariable ["itc_land_guidance_targetAlt",0] +]; + +[{ + params ["_pfhValues","_pfhId"]; + _pfhValues params ["_projectile", "_magazine", "_position", "_fuzeType","_fuzeTime", "_firedTime","", "_guidanceInfo"]; + + if (alive _projectile) then { + _position = getPosATL _projectile; + _pfhValues set [2, _position]; + }; + + _triggered = time > _firedTime + _fuzeTime; + + if(_triggered && alive _projectile) exitWith { + _subMunitionScript = configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunitionScript"; + _subMunitionCount = getNumber (configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunitionCount"); + (_projectile call BIS_fnc_getPitchBank) params ["_pitch", "_bank"]; + if (isText _subMunitionScript) then { + for "_i" from 1 to _subMunitionCount step 1 do { + [_i, getPosASL _projectile, velocity _projectile, _pitch, _bank, _guidanceInfo] call (missionNamespace getVariable [getText _subMunitionScript, {}]); + }; + }; + + deleteVehicle _projectile; + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; + + if(!alive _projectile) exitWith { + [_pfhId] call CBA_fnc_removePerFrameHandler; + }; +}, 0, [_projectile, _magazine, getPosATL _projectile, _fuzeType, _fuzeValue, time,[0,0,0], _guidanceInfo]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_firedSAM35.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedSAM35.sqf new file mode 100644 index 0000000..06ecbc1 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_firedSAM35.sqf @@ -0,0 +1,59 @@ +/* + * Author: Toadball + * Fired event for ITC SAM systems with SAM35 fuzed munitions + */ +//diag_log format ["LAUNCH: SAM35 Fuze START"]; +params ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile", "_launcher"]; +if (!local _launcher) exitWith {}; +//diag_log format ["LAUNCH: SAM35 Fuze Active"]; +private _projAD = getNumber (configFile >> "CfgAmmo" >> _ammo >> "fuseDistance"); //How far from the launcher should the missile before before the sensor is active +private _proxHelper = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunition"); //What ammunition class is to be used for the simulated detonation +private _fuzeType = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_fuze"); +private _fuzeConfig = configFile >> "ITC_Land_CfgFuzes" >> _fuzeType; +private _sensorFOV = getNumber (_fuzeConfig >> "proxFOV"); //What is the sensor's FOV in degrees +private _sensorRAN = getNumber (_fuzeConfig >> "proxRAN"); //What is the range of the sensor - how close does the missile have to get before the proximity fuze is tripped + +//diag_log format ["PARAMS // %1 // %2 // %3 // %4 // %5 // %6 // %7 // %8 //",_launcher,_projectile,_projAD,_fuzeType,_fuzeConfig,_sensorFOV,_sensorRAN,_proxHelper]; +[ + { + private ["_projPos","_spawnedproj","_nearTargets","_vectorDirMissile","_vectorToTarget","_tgt","_targetAngle"]; + + (_this select 0) params ["_launcher","_projectile","_projAD","_sensorFOV","_sensorRAN","_proxHelper"]; + + //if the missile is alive do the fuse check, if not remove this PFH + if (!isNull _projectile) then { + //drop ["\a3\data_f\Cl_basic","","Billboard",0.25,60,position _projectile,[0,0,0],1,1.275,1.0,0.0,[2],[[0,1,0,1]],[0],0.0,2.0,"","",""]; + // proximity check: if there is an air object within sensor range of the projectile + _nearTargets = nearestObjects [_projectile, ["Air"], _sensorRAN]; + if (_launcher distance _projectile > _projAD && count (_nearTargets) > 0) then { + _tgt = (_nearTargets) select 0; //get closest air object in sensor range + //diag_log format ["SEARCHING: TARGET = %1 @ %2m",_tgt,(_projectile distance _tgt)]; + + //check object is in sensor's FOV, if it is, projectile go boom + _vectorDirMissile = vectorDir _projectile; + _vectorToTarget = (getposASL _projectile) vectorFromTo (getposASL _tgt); + _targetAngle = acos (_vectorDirMissile vectorCos _vectorToTarget); + + //diag_log format ["Target angle: %3", _vectorDirMissile, _vectorToTarget, _targetAngle]; + //diag_log format ["SENSOR // %1 // %2 // %3 // %4 //",_projectile,_sensorFOV,_sensorRAN,_proxHelper]; + + + if (_targetAngle > (0+_sensorFOV) && _targetAngle < (180-_sensorFOV)) then { + _projPos = getPos _projectile; + deleteVehicle _projectile; + if (isServer) then { + _spawnedproj = _proxHelper createVehicle _projPos; + //drop ["\a3\data_f\Cl_basic","","Billboard",0.25,60,position _projectile,[0,0,0],1,1.275,1.0,0.0,[2],[[1,0,0,1]],[0],0.0,2.0,"","",""]; + }; + //diag_log format ["DET: %1 @ %2",_projectile,diag_ticktime]; + }; + } else {}; + + } else { + //diag_log format ["MISSILE LOST: SAM35 Fuze Terminating"]; + [_this select 1] call CBA_fnc_removePerFrameHandler; //removes prox fuse PFH + }; + // PFH FNC End + }, 0, [_launcher,_projectile,_projAD,_sensorFOV,_sensorRAN,_proxHelper] +] call CBA_fnc_addPerFrameHandler; + diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeDelay.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeDelay.sqf new file mode 100644 index 0000000..79944c7 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeDelay.sqf @@ -0,0 +1,30 @@ +params ["_pfhValues","_pfhId"]; +_pfhValues params ["_projectile", "_magazine", "_position", "_fuzeType","_fuzeTime", "_lastFrameTime","_velocity"]; + +if (alive _projectile) then { + _position = getPosATL _projectile; + _pfhValues set [2, _position]; + _velocity = velocity _projectile; + if(vectorMagnitude _velocity > 10) then { + _pfhValues set [6, _velocity]; + }; +}; + +if(!alive _projectile) exitWith { + [_pfhId] call CBA_fnc_removePerFrameHandler; + _subMunition = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunition"); + //_lastFrameLength = time - _lastFrameTime; + _lastSpeed = vectorMagnitude _velocity; + //player sideChat format["last speed %1ms based on %2",_lastSpeed,_velocity]; + _lastFrameDist = _fuzeTime * _lastSpeed; + _lastExplosionVector = (vectorNormalized _velocity) vectorMultiply _lastFrameDist; + //player sideChat format ["delay fuze, distance %1 ", _lastFrameDist]; + _explosionPosition = _position vectorAdd _lastExplosionVector; + _subMunition createVehicle _explosionPosition; + + //drop ["\a3\data_f\Cl_basic","","Billboard",1,20,_position,[0,0,0],1,1.275,1.0,0.0,[1],[[1,0,0,1]],[0],0.0,2.0,"","",""]; + //drop ["\a3\data_f\Cl_basic","","Billboard",1,20,_explosionPosition,[0,0,0],1,1.275,1.0,0.0,[1],[[238,255,0,1]],[0],0.0,2.0,"","",""]; +}; + + +_pfhValues set [5, time]; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProx.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProx.sqf new file mode 100644 index 0000000..4f1a6e2 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProx.sqf @@ -0,0 +1,14 @@ +params ["_pfhValues","_pfhId"]; +_pfhValues params ["_projectile", "_magazine", "_position", "_fuzeType","_fuzeValue", "",""]; + +if (alive _projectile) then { + _position = getPosATL _projectile; + _pfhValues set [2, _position]; +}; + +_alt = (getPosATL _projectile) select 2; +if((_alt < _fuzeValue && (velocity _projectile) # 2 < 0) || !alive _projectile) exitWith { + _subMunition = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunition"); + deleteVehicle _projectile; _subMunition createVehicle _position; + [_pfhId] call CBA_fnc_removePerFrameHandler; +}; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProxFOV.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProxFOV.sqf new file mode 100644 index 0000000..1302f03 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeProxFOV.sqf @@ -0,0 +1,55 @@ +//player sideChat "LAUNCH"; +private _args = _this # 0; +private _launcher = _args # 0; +private _proj = _args # 6; +private _magazine = _args # 5; +private _projAD = getNumber (configFile >> "CfgAmmo" >> (_args select 4) >> "fuseDistance"); //How far from the launcher should the missile before before the sensor is active + +private _proxHelper = getText (configFile >> "CfgMagazine" >> _magazine >> "itc_land_submunition"); //What ammunition class is to be used for the simulated detonation + +private _fuzeType = getText (configFile >> "CfgMagazine" >> _magazine >> "itc_land_fuze"); +private _fuzeConfig = configFile >> "ITC_Land_CfgFuzes" >> _fuzeType; +private _sensorFOV = getNumber (_fuzeConfig >> "itc_air_sensorFOV"); //What is the sensor's FOV in degrees +private _sensorRAN = getNumber (_fuzeConfig >> _magazine >> "itc_air_sensorRAN"); //What is the range of the sensor - how close does the missile have to get before the proximity fuze is tripped + +//player sideChat format ["%1 %2 %3 %4 %5 %6",_launcher,_proj,_projAD,_proxHelper,_sensorFOV,_sensorRAN]; +private ["_projPos","_spawnedproj","_nearTargets","_vectorDirMissile","_vectorToTarget","_tgt","_targetAngle"]; + +//if the missile is alive do the fuse check, if not remove this PFH +if (!isNull _proj) then { + //drop ["\a3\data_f\Cl_basic","","Billboard",0.25,60,position _proj,[0,0,0],1,1.275,1.0,0.0,[2],[[0,1,0,1]],[0],0.0,2.0,"","",""]; + // proximity check: if there is an air object within sensor range of the projectile + _nearTargets = nearestObjects [_proj, [], _sensorRAN]; + if (_launcher distance _proj > _projAD && count (_nearTargets) > 0) then { + _tgt = (_nearTargets) select 0; //get closest air object in sensor range + + //diag_log format ["Timer 1: %1",diag_ticktime]; + + //check object is in sensor's FOV, if it is, projectile go boom + _vectorDirMissile = vectorDir _proj; + _vectorToTarget = (getposASL _proj) vectorFromTo (getposASL _tgt); + _targetAngle = acos (_vectorDirMissile vectorCos _vectorToTarget); + + //diag_log format ["Timer 2: %1",diag_ticktime]; + + //hintsilent format ["Target angle: %3", _vectorDirMissile, _vectorToTarget, _targetAngle]; + //diag_log format ["Target angle: %3", _vectorDirMissile, _vectorToTarget, _targetAngle]; + + //diag_log format ["Timer 3: %1",diag_ticktime]; + + if (_targetAngle > 60 && _targetAngle < 120) then { + triggerAmmo _proj; + /*_projPos = getPos _proj; + deleteVehicle _proj; + if (isServer) then { + _spawnedproj = _proxHelper createVehicle _projPos; + //drop ["\a3\data_f\Cl_basic","","Billboard",0.25,60,position _proj,[0,0,0],1,1.275,1.0,0.0,[2],[[1,0,0,1]],[0],0.0,2.0,"","",""]; + }; + */ + //diag_log format ["Detonation: %1",diag_ticktime]; + }; + }; + +} else { + [_this select 1] call CBA_fnc_removePerFrameHandler; //removes prox fuse PFH +}; diff --git a/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeTime.sqf b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeTime.sqf new file mode 100644 index 0000000..7fca367 --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/functions/fn_fuzeTime.sqf @@ -0,0 +1,25 @@ +params ["_pfhValues","_pfhId"]; +_pfhValues params ["_projectile", "_magazine", "_position", "_fuzeType","_fuzeTime", "_firedTime",""]; + +if (alive _projectile) then { + _position = getPosATL _projectile; + _pfhValues set [2, _position]; +}; + +_triggered = time > _firedTime + _fuzeTime; + +if(_triggered || !alive _projectile) exitWith { + + _vProj = velocity _projectile; + _dProj = getDir _projectile; + _pbProj = _projectile call BIS_fnc_getPitchBank; + [_pfhId] call CBA_fnc_removePerFrameHandler; + deleteVehicle _projectile; + + _subMunitionClass = getText (configFile >> "CfgMagazines" >> _magazine >> "itc_land_submunition"); + _subMunition = createVehicle [_subMunitionClass, _position, [], 0, "FLY"]; + _subMunition setDir _dProj; + ([_subMunition] + _pbProj) call BIS_fnc_setPitchBank; + _subMunition setVelocity _vProj; + +}; diff --git a/addons/ITCExpansionGuidanceFuzes/script_component.hpp b/addons/ITCExpansionGuidanceFuzes/script_component.hpp new file mode 100644 index 0000000..ef4175e --- /dev/null +++ b/addons/ITCExpansionGuidanceFuzes/script_component.hpp @@ -0,0 +1,14 @@ +#define COMPONENT ITCExpansionGuidanceFuzes +#include "\z\TF47\addons\main\script_mod.hpp" + +#define DEBUG_MODE_FULL +// #define DISABLE_COMPILE_CACHE + +#ifdef DEBUG_ENABLED_DATABASE + #define DEBUG_MODE_FULL +#endif + #ifdef DEBUG_SETTINGS_DATABASE + #define DEBUG_SETTINGS DEBUG_SETTINGS_DATABASE +#endif + +#include "\z\TF47\addons\main\script_macros.hpp" diff --git a/addons/ITCExpansionSpike/$PBOPREFIX$ b/addons/ITCExpansionSpike/$PBOPREFIX$ new file mode 100644 index 0000000..0a84027 --- /dev/null +++ b/addons/ITCExpansionSpike/$PBOPREFIX$ @@ -0,0 +1 @@ +z\TF47\addons\ITCExpansionSpike \ No newline at end of file diff --git a/addons/ITCExpansionSpike/config.cpp b/addons/ITCExpansionSpike/config.cpp new file mode 100644 index 0000000..949f254 --- /dev/null +++ b/addons/ITCExpansionSpike/config.cpp @@ -0,0 +1,21 @@ +class CfgPatches { + class itc_land_spike { + author = "ITC Addons Team"; + authors[] = {"TF47 Desty"}; + requiredaddons[] = {"A3_Weapons_F"}; + requiredversion = 1.9; + units[] = {}; + weapons[] = {"tf47_itc_land_spikeLR"}; + magazines[] = {"tf47_itc_land_spikeLR_1rnd"}; + }; +}; +class NewTurret; + +#include "config\baseControls.hpp" +#include "config\CfgAmmo.hpp" +#include "config\CfgMagazines.hpp" +#include "config\CfgWeapons.hpp" +#include "config\CfgVehicles.hpp" +#include "config\cfgFunctions.hpp" +#include "config\ace_missileguidance_AttackProfiles.hpp" +#include "config\ITC_Land_SpikeSeeker.hpp" diff --git a/addons/ITCExpansionSpike/config/CfgMagazines.hpp b/addons/ITCExpansionSpike/config/CfgMagazines.hpp new file mode 100644 index 0000000..6faa188 --- /dev/null +++ b/addons/ITCExpansionSpike/config/CfgMagazines.hpp @@ -0,0 +1,10 @@ +class CfgMagazines { + class Titan_AT; + class tf47_itc_land_spikeLR_2rnd: Titan_AT { + ammo = "itc_land_spikeLR"; + displayName = "Spike LR"; + }; + class tf47_itc_land_spikeLR_1rnd: tf47_itc_land_spikeLR_2rnd { + count = 1; + }; +}; diff --git a/addons/ITCExpansionSpike/config/CfgVehicles.hpp b/addons/ITCExpansionSpike/config/CfgVehicles.hpp new file mode 100644 index 0000000..14e39f7 --- /dev/null +++ b/addons/ITCExpansionSpike/config/CfgVehicles.hpp @@ -0,0 +1,62 @@ +class CfgVehicles { + class LandVehicle; + class StaticWeapon: LandVehicle { + class Turrets { + class MainTurret: NewTurret {}; + }; + }; + class StaticMGWeapon: StaticWeapon { + class Turrets: Turrets { + class MainTurret: MainTurret {}; + }; + }; + class AT_01_base_F: StaticMGWeapon {}; + class B_static_AT_F: AT_01_base_F { + class SimpleObject; + class Turrets: Turrets { + class MainTurret: MainTurret {}; + }; + class AnimationSources { + class muzzle_source; + class muzzle_source_rot; + class ReloadAnim; + class ReloadMagazine; + class Revolving; + }; + }; + class ITC_Land_B_SpikeLR: B_static_AT_F { + displayName = "Spike LR ATGM [NATO]"; + model = "\A3\Static_F_Gamma\AA_01\AA_01.p3d"; + + class SimpleObject: SimpleObject {}; + editorPreview = "\A3\EditorPreviews_F_Exp\Data\CfgVehicles\B_T_Static_AA_F.jpg"; + hiddenSelections[] = {"camo_launcher","camo_tube"}; + hiddenSelectionsTextures[] = {"\a3\weapons_f_exp\launchers\titan\data\launch_b_titan_tna_f_01_co.paa","\a3\weapons_f_exp\launchers\titan\data\launch_b_titan_tna_f_02_co.paa"}; + class Turrets: Turrets { + class MainTurret: MainTurret { + weapons[] = {"tf47_itc_land_spikeLR_atgm"}; + magazines[] = {"tf47_itc_land_spikeLR_1rnd","tf47_itc_land_spikeLR_1rnd","tf47_itc_land_spikeLR_1rnd","tf47_itc_land_spikeLR_1rnd"}; + }; + }; + class Armory { + description = " "; + }; + class AnimationSources: AnimationSources { + class muzzle_source: muzzle_source { + weapon = "tf47_itc_land_spikeLR_atgm"; + }; + class muzzle_source_rot: muzzle_source_rot { + weapon = "tf47_itc_land_spikeLR_atgm"; + }; + class ReloadAnim: ReloadAnim { + weapon = "tf47_itc_land_spikeLR_atgm"; + }; + class ReloadMagazine: ReloadMagazine { + weapon = "tf47_itc_land_spikeLR_atgm"; + }; + class Revolving: Revolving { + weapon = "tf47_itc_land_spikeLR_atgm"; + }; + }; + }; +}; diff --git a/addons/ITCExpansionSpike/config/CfgWeapons.hpp b/addons/ITCExpansionSpike/config/CfgWeapons.hpp new file mode 100644 index 0000000..58ab99f --- /dev/null +++ b/addons/ITCExpansionSpike/config/CfgWeapons.hpp @@ -0,0 +1,48 @@ +class CfgWeapons { + + //class missiles_titan; + //class itc_land_spikeLR_atgm: missiles_titan { + // magazines[] = {"itc_land_spikeLR_2rnd","itc_land_spikeLR_1rnd"}; + //}; + + //class launch_I_Titan_short_F; + //class PSZ_Spike_LR: launch_I_Titan_short_F { + class launch_B_Titan_F; + class tf47_itc_land_spikeLR: launch_B_Titan_F { + displayName = "Spike LR"; + displayNameShort = "Spike LR"; + //hiddenSelectionsTextures[] = {"A3\Weapons_F_Beta\Launchers\Titan\Data\Launcher_CO.paa","A3\Weapons_F_Beta\Launchers\Titan\Data\TubeL_CO.paa"}; + picture = "\A3\Weapons_F_Enoch\Launchers\Titan\Data\UI\icon_launch_B_Titan_olive_F_ca.paa"; + hiddenSelectionsTextures[] = {"\a3\weapons_f_beta\launchers\titan\data\launcher_indp_co.paa","\A3\Weapons_F_Enoch\Launchers\Titan\Data\launch_B_Titan_olive_F_02_co.paa"}; + magazines[] = {"tf47_itc_land_spikeLR_1rnd"}; + magazineWell[] = {}; + class EventHandlers { + class itc_land_spike { + fired = "_this call itc_land_spike_fnc_fired;"; + }; + }; + canLock = 0; + weaponInfoType = "ITC_Land_SpikeOptics"; + modelOptics="\A3\Weapons_F\empty.p3d"; + class OpticsModes { + class StepScope { + cameraDir = "look"; + discretefov[] = {0.08333,0.04167}; + discreteInitIndex = 0; + distanceZoomMax = 300; + distanceZoomMin = 300; + memoryPointCamera = "eye"; + opticsDisablePeripherialVision = 1; + opticsFlare = 0; + opticsID = 1; + opticsPPEffects[] = {"OpticsCHAbera1","OpticsBlur1"}; + opticsZoomInit = 0.08333; + opticsZoomMax = 0.04167; + opticsZoomMin = 0.08333; + thermalMode[] = {0,1}; + useModelOptics = 1; + visionMode[] = {"Normal","Ti"}; + }; + }; + }; +}; diff --git a/addons/ITCExpansionSpike/config/ITC_Land_SpikeSeeker.hpp b/addons/ITCExpansionSpike/config/ITC_Land_SpikeSeeker.hpp new file mode 100644 index 0000000..5800757 --- /dev/null +++ b/addons/ITCExpansionSpike/config/ITC_Land_SpikeSeeker.hpp @@ -0,0 +1,406 @@ +class RscTitles { + class ITC_Land_SpikeSeeker { + idd = 86005; + movingEnable = 1; + duration = 9999999; + fadein = 0; + fadeout = 0; + onLoad = "uiNamespace setVariable [""itc_land_spike_ui"",(_this select 0)];"; // ((_this select 0) displayCtrl -1) progressSetPosition 0.5 + + class controls { + class Sidebar_Left: RscText { + idc = 1009; + x = "0 * (safezoneW / 64) + (0)"; + y = "0 * (safezoneH / 40) + (0)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + class Sidebar_Right: RscText { + idc = 1010; + x = "52 * (safezoneW / 64) + (0)"; + y = "0 * (safezoneH / 40) + (0)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + shadow = 0; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + + class VisionMode: Sidebar_Right { + idc = 1011; + style = 0; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "1 * (safezoneH / 40) + (0)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "HOT"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + + class HotBox: RscPicture { + idc = 1018; + x = "13.5 * (safezoneW / 64) + (0)"; + y = "1 * (safezoneH / 40) + (0)"; + w = "1.12 * (safezoneW / 64)"; + h = "1.12 * (safezoneH / 40)"; + text = "\A3\Ui_f\data\IGUI\RscIngameUI\RscOptics\square.paa"; + }; + + class TimerProgress: RscProgress { + idc = -1; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "2.75 * (safezoneH / 40) + (0)"; + w = "4 * (safezoneW / 64)"; + h = "1* (safezoneH / 40)"; + colorFrame[] = {2,2,2,1}; + colorBar[] = {1,1,1,1}; + texture = "#(argb,8,8,3)color(1,1,1,1)"; + }; + class TimerText: Sidebar_Right { + idc = 1013; + style = 0; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "4 * (safezoneH / 40) + (0)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "0234"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + //Centre elements + class ManualText: Sidebar_Right { + idc = 1016; + style = 2; + x = "27 * (safezoneW / 64) + (0)"; + y = "10 * (safezoneH / 40) + (0)"; + w = "10 * (safezoneW / 64)"; + h = "3 * (safezoneH / 40)"; + text = "MANUAL"; + font = "EtelkaMonospacePro"; + fixedWidth = 1; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 2.5)"; + }; + /*class SeekerFrame: RscFrame { + x = "25 * (safezoneW / 64) + (0)"; + y = "13 * (safezoneH / 40) + (0)"; + w = "14 * (safezoneW / 64)"; + h = "14 * (safezoneH / 40)"; + };*/ + class SeekerBox: RscPicture { + idc = 1020; + x = "25 * (safezoneW / 64) + (0)"; + y = "13 * (safezoneH / 40) + (0)"; + w = "14 * (safezoneW / 64)"; + h = "14 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerBox.paa"; + }; + class SeekerT: RscPicture { + idc = 1021; + x = "22 * (safezoneW / 64) + (0)"; + y = "10 * (safezoneH / 40) + (0)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerT.paa"; + }; + class ModeText: Sidebar_Right { + idc = 1014; + style = 0; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "37.5 * (safezoneH / 40) + (0)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "00 LOW"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + class DateTimeText: Sidebar_Right { + idc = 1015; + style = 1; + x = "39 * (safezoneW / 64) + (0)"; + y = "37.5 * (safezoneH / 40) + (0)"; + w = "12 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "11/01/20 14:50"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + }; + }; +}; +class ITC_Land_SpikeSeeker { + idd = 86005; + movingEnable = 1; + duration = 9999999; + fadein = 0; + fadeout = 0; + hideCursor = 1; + onLoad = "uiNamespace setVariable [""itc_land_spike_ui"",(_this select 0)];"; // ((_this select 0) displayCtrl -1) progressSetPosition 0.5 + + class controls { + class VisionMode: RscText { + idc = 1011; + style = 0; + x = "14.5 * (safezoneW / 64) + (safeZoneX)"; + y = "1 * (safezoneH / 40) + (safeZoneY)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "HOT"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + + class HotBox: RscPicture { + idc = 1018; + x = "13.5 * (safezoneW / 64) + (safeZoneX)"; + y = "1 * (safezoneH / 40) + (safeZoneY)"; + w = "1.12 * (safezoneW / 64)"; + h = "1.12 * (safezoneH / 40)"; + text = "\A3\Ui_f\data\IGUI\RscIngameUI\RscOptics\square.paa"; + }; + + class TimerProgress: RscProgress { + idc = -1; + x = "14.5 * (safezoneW / 64) + (safeZoneX)"; + y = "2.75 * (safezoneH / 40) + (safeZoneY)"; + w = "4 * (safezoneW / 64)"; + h = "1* (safezoneH / 40)"; + colorFrame[] = {2,2,2,1}; + colorBar[] = {1,1,1,1}; + texture = "#(argb,8,8,3)color(1,1,1,1)"; + }; + class TimerText: VisionMode { + idc = 1013; + style = 0; + x = "14.5 * (safezoneW / 64) + (safeZoneX)"; + y = "4 * (safezoneH / 40) + (safeZoneY)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "0234"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + //Centre elements + class ManualText: VisionMode { + idc = 1016; + style = 2; + x = "27 * (safezoneW / 64) + (safeZoneX)"; + y = "10 * (safezoneH / 40) + (safeZoneY)"; + w = "10 * (safezoneW / 64)"; + h = "3 * (safezoneH / 40)"; + text = "MANUAL"; + font = "EtelkaMonospacePro"; + fixedWidth = 1; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 2.5)"; + }; + /*class SeekerFrame: RscFrame { + x = "25 * (safezoneW / 64) + (0)"; + y = "13 * (safezoneH / 40) + (0)"; + w = "14 * (safezoneW / 64)"; + h = "14 * (safezoneH / 40)"; + };*/ + class SeekerBox: RscPicture { + idc = 1020; + x = "25 * (safezoneW / 64) + (safeZoneX)"; + y = "13 * (safezoneH / 40) + (safeZoneY)"; + w = "14 * (safezoneW / 64)"; + h = "14 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerBox.paa"; + }; + class SeekerT: RscPicture { + idc = 1021; + x = "22 * (safezoneW / 64) + (safeZoneX)"; + y = "10 * (safezoneH / 40) + (safeZoneY)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerT.paa"; + }; + class SeekerTL: RscPicture { + idc = 1022; + x = "22 * (safezoneW / 64) + (safeZoneX)"; + y = "10 * (safezoneH / 40) + (safeZoneY)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerTL.paa"; + }; + class ModeText: VisionMode { + idc = 1014; + style = 0; + x = "14.5 * (safezoneW / 64) + (safeZoneX)"; + y = "37.5 * (safezoneH / 40) + (safeZoneY)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "21 HIGH"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + class DateTimeText: VisionMode { + idc = 1015; + style = 1; + x = "39 * (safezoneW / 64) + (safeZoneX)"; + y = "37.5 * (safezoneH / 40) + (safeZoneY)"; + w = "12 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "11/01/20 14:50"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + class Sidebar_Left: RscText { + idc = 1009; + x = "0 * (safezoneW / 64) + (safeZoneX)"; + y = "0 * (safezoneH / 40) + (safeZoneY)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + class Sidebar_Right: RscText { + idc = 1010; + x = "52 * (safezoneW / 64) + (safeZoneX)"; + y = "0 * (safezoneH / 40) + (safeZoneY)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + shadow = 0; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + }; +}; + +class RscIngameUI { + class RscOptics_LaserDesignator_02; + class ITC_Land_SpikeOptics: RscOptics_LaserDesignator_02 { + idd = 300; + controls[] = {"CA_IGUI_elements_group"}; + onLoad = "_this call itc_land_spike_fnc_selectSpike"; + class CA_IGUI_elements_group: RscControlsGroup + { + idc = 170; + class VScrollbar: VScrollbar + { + width = 0; + }; + class HScrollbar: HScrollbar + { + height = 0; + }; + x = "safeZoneX"; + y = "safeZoneY"; + w = "safeZoneW"; + h = "safeZoneH"; + class controls + { + class Sidebar_Left: RscText { + idc = 1009; + x = "0 * (safezoneW / 64) + (0)"; + y = "0 * (safezoneH / 40) + (0)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + class Sidebar_Right: RscText { + idc = 1010; + x = "52 * (safezoneW / 64) + (0)"; + y = "0 * (safezoneH / 40) + (0)"; + w = "12 * (safezoneW / 64)"; + h = "(safezoneH)"; + shadow = 0; + colorBackground[] = {0,0,0,1}; + colorText[] = {"172/255","255/255","153/255",1}; + }; + class HotBox: RscPicture { + idc = 1018; + x = "13.5 * (safezoneW / 64) + (safeZoneX)"; + y = "1 * (safezoneH / 40) + (safeZoneY)"; + w = "1.12 * (safezoneW / 64)"; + h = "1.12 * (safezoneH / 40)"; + text = "\A3\Ui_f\data\IGUI\RscIngameUI\RscOptics\square.paa"; + }; + + class TimerProgress: RscProgress { + idc = -1; + x = "14.5 * (safezoneW / 64) + (safeZoneX)"; + y = "2.75 * (safezoneH / 40) + (safeZoneY)"; + w = "4 * (safezoneW / 64)"; + h = "1* (safezoneH / 40)"; + colorFrame[] = {2,2,2,1}; + colorBar[] = {1,1,1,1}; + texture = "#(argb,8,8,3)color(1,1,1,1)"; + }; + class SeekerBox: RscPicture { + idc = 1020; + x = "22 * (safezoneW / 64) + (0)"; + y = "10 * (safezoneH / 40) + (0)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerBox.paa"; + }; + class SeekerT: RscPicture { + idc = 1021; + x = "22 * (safezoneW / 64) + (0)"; + y = "10 * (safezoneH / 40) + (0)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerT.paa"; + }; + class SeekerTL: RscPicture { + idc = 1022; + x = "22 * (safezoneW / 64) + (0)"; + y = "10 * (safezoneH / 40) + (0)"; + w = "20 * (safezoneW / 64)"; + h = "20 * (safezoneH / 40)"; + text = "itc_land_spike\data\seekerTL.paa"; + }; + class VisionMode: Sidebar_Right { + idc = 1011; + style = 0; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "1 * (safezoneH / 40) + (0)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "DTV"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + class ModeText: VisionMode { + idc = 1014; + style = 0; + x = "14.5 * (safezoneW / 64) + (0)"; + y = "37.5 * (safezoneH / 40) + (0)"; + w = "6 * (safezoneW / 64)"; + h = "1.5 * (safezoneH / 40)"; + text = "21 HIGH"; + font = "LCD14"; + colorText[] = {1,1,1,1}; + colorBackground[] = {0,0,0,0}; + SizeEx = "( ( ( ((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1.5)"; + }; + }; // controls + }; // CA_IGUI_elements_group + }; // ITC_Land_SpikeOptics +}; // RscIngameUI diff --git a/addons/ITCExpansionSpike/config/ace_missileguidance_AttackProfiles.hpp b/addons/ITCExpansionSpike/config/ace_missileguidance_AttackProfiles.hpp new file mode 100644 index 0000000..c393242 --- /dev/null +++ b/addons/ITCExpansionSpike/config/ace_missileguidance_AttackProfiles.hpp @@ -0,0 +1,10 @@ + +class ace_missileguidance_AttackProfiles { + class itc_land_spike_guidance { + description = ""; + onFired = ""; + functionName = "itc_land_spike_fnc_guidance"; + name = ""; + visualName = ""; + }; +}; diff --git a/addons/ITCExpansionSpike/config/baseControls.hpp b/addons/ITCExpansionSpike/config/baseControls.hpp new file mode 100644 index 0000000..29e835b --- /dev/null +++ b/addons/ITCExpansionSpike/config/baseControls.hpp @@ -0,0 +1,15 @@ + +class RscMapControl; +class IGUIBack; +class RscEdit; +class RscText; +class RscStructuredText; +class RscControlsGroup; +class RscControlsGroupNoScrollbars; +class RscFrame; +class RscListBox; +class RscButton; +class RscPicture; +class RscProgress; +class VScrollbar; +class HScrollbar; diff --git a/addons/ITCExpansionSpike/config/cfgAmmo.hpp b/addons/ITCExpansionSpike/config/cfgAmmo.hpp new file mode 100644 index 0000000..6c914fa --- /dev/null +++ b/addons/ITCExpansionSpike/config/cfgAmmo.hpp @@ -0,0 +1,40 @@ +class CfgAmmo { + class M_Titan_AT; + class tf47_itc_land_spikeLR: M_Titan_AT { + irLock = 1; + laserLock = 0; + airLock = 0; + timeToLive = 50; + // Turn off arma crosshair-guidance + manualControl = 0; + + caliber = 230; + hit = 1000; // default: 800 + indirectHit = 20; + indirectHitRange = 2; + // ACE uses these values + //trackOversteer = 1; + //trackLead = 0; + + initTime = 0; + class ace_missileguidance { + attackProfiles[] = {"itc_land_spike_guidance"}; + canVanillaLock = 0; + defaultAttackProfile = "itc_land_spike_guidance"; + defaultSeekerLockMode = ""; + defaultSeekerType = ""; + enabled = 1; + minDeflection = 0.00005; // Minium flap deflection for guidance + maxDeflection = 0.0025; // Maximum flap deflection for guidance + incDeflection = 0.00005; // The incrmeent in which deflection adjusts. + seekerAccuracy = 1; + seekerAngle = 180; + seekerLockModes[] = {"LOBL"}; + seekerMaxRange = 4000; + seekerMinRange = 0; + seekerTypes[] = {"Optic"}; + seekLastTargetPos = 1; + useModeForAttackProfile = 0; + }; + }; +}; diff --git a/addons/ITCExpansionSpike/config/cfgFunctions.hpp b/addons/ITCExpansionSpike/config/cfgFunctions.hpp new file mode 100644 index 0000000..2d0231e --- /dev/null +++ b/addons/ITCExpansionSpike/config/cfgFunctions.hpp @@ -0,0 +1,20 @@ +class CfgFunctions { + class TF47 { + class ITCExpansionSpike { + file = "z\TF47\addons\ITCExpansionSpike\functions"; + class init {postInit = 1;}; + class selectSpike {}; + class sightViewChanged {}; + class sightClosed {}; + class fired {}; + class cameraUpdate {}; + class updateSightOverlay {}; + class handleLock {}; + class intersectScreenToWorld {}; + class intersectAtPolar {}; + class startCamera {}; + class guidance {}; + class handleCameraAiming {}; + }; + }; +}; diff --git a/addons/ITCExpansionSpike/data/seekerT.paa b/addons/ITCExpansionSpike/data/seekerT.paa new file mode 100644 index 0000000..9b3a2f0 Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerT.paa differ diff --git a/addons/ITCExpansionSpike/data/seekerT.png b/addons/ITCExpansionSpike/data/seekerT.png new file mode 100644 index 0000000..6935ddf Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerT.png differ diff --git a/addons/ITCExpansionSpike/data/seekerTL.paa b/addons/ITCExpansionSpike/data/seekerTL.paa new file mode 100644 index 0000000..797502f Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerTL.paa differ diff --git a/addons/ITCExpansionSpike/data/seekerTL.png b/addons/ITCExpansionSpike/data/seekerTL.png new file mode 100644 index 0000000..133c348 Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerTL.png differ diff --git a/addons/ITCExpansionSpike/data/seekerbox.paa b/addons/ITCExpansionSpike/data/seekerbox.paa new file mode 100644 index 0000000..a460271 Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerbox.paa differ diff --git a/addons/ITCExpansionSpike/data/seekerbox.png b/addons/ITCExpansionSpike/data/seekerbox.png new file mode 100644 index 0000000..6900de1 Binary files /dev/null and b/addons/ITCExpansionSpike/data/seekerbox.png differ diff --git a/addons/ITCExpansionSpike/data/spike_seeker_elements.psd b/addons/ITCExpansionSpike/data/spike_seeker_elements.psd new file mode 100644 index 0000000..b3f112d Binary files /dev/null and b/addons/ITCExpansionSpike/data/spike_seeker_elements.psd differ diff --git a/addons/ITCExpansionSpike/functions/fn_cameraUpdate.sqf b/addons/ITCExpansionSpike/functions/fn_cameraUpdate.sqf new file mode 100644 index 0000000..23b8c92 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_cameraUpdate.sqf @@ -0,0 +1,57 @@ +/* + * itc_land_spike_fnc_cameraUpdate + */ +params ["_display"]; +if (!itc_land_spike_ppEffect) then { + "colorCorrections" ppEffectAdjust [0.9, 0.4, 0, [0.9, 0.4, 0, 0], [1, 1, 1, 0], [1, 1, 1, 0]];; + "colorCorrections" ppEffectCommit 0; + "colorCorrections" ppEffectEnable true; + + "filmGrain" ppEffectAdjust [0.5, 2, 1, 1, 1]; + "filmGrain" ppEffectCommit 0; + "filmGrain" ppEffectEnable true; + itc_land_spike_ppEffect = true; +}; +itc_land_spike_camera camSetPos (itc_land_spike_currentMissile modelToWorld [0,1,0]); +private _polarToTarget = ((getPosASL itc_land_spike_currentMissile) vectorFromTo itc_land_spike_targetPosCamera) call cba_fnc_vect2polar; +itc_land_spike_camera setDir (_polarToTarget # 1); +private _timePassed = time - itc_land_spike_launchTime; +private _bank = if (time > itc_land_spike_launchTime + ((itc_land_spike_wobble # 2)*pi)) then {0} else {sin deg (4*(_timePassed) + 3.2) * (itc_land_spike_wobble # 1)}; +[itc_land_spike_camera, (_polarToTarget # 2), _bank * (itc_land_spike_wobble # 0)] call bis_fnc_setpitchbank; +itc_land_spike_camera camCommit 0; + +private _ui = uiNamespace getVariable "itc_land_spike_ui"; +if (isNull _ui || isNil "itc_land_spike_camera") exitWith { + itc_land_spike_camera cameraEffect ["terminate", "back"]; + camDestroy itc_land_spike_camera; + itc_land_spike_camera = nil; + "colorCorrections" ppEffectEnable false; + "filmGrain" ppEffectEnable false; + itc_land_spike_ppEffect = false; +}; +(_ui displayCtrl 1011) ctrlShow false; +(_ui displayCtrl 1018) ctrlShow false; +(_ui displayCtrl -1) ctrlShow false; +(_ui displayCtrl 1020) ctrlShow false; +(_ui displayCtrl 1015) ctrlShow (time < (itc_land_spike_launchTime + 5)); +(_ui displayCtrl 1013) ctrlSetText str (round ((time - itc_land_spike_activationTime) * 100)); +(_ui displayCtrl 1015) ctrlSetText (format ["%1/%2/%3 %4:%5", date # 2, date # 1, date # 0, date # 3, date # 4]); +itc_land_spike_lockInformation params ["_lockObject", "_lockPosition", "_lockLostTime", "_originalLockPosition"]; +private _screenPos = (worldToScreen (ASLtoAGL itc_land_spike_targetPos)); +if (!isNil "_lockObject") then { + _screenPos = worldToScreen (_lockObject modelToWorld _lockPosition); +}; +_screenPos params ["_x", "_y"]; +if (isNil "_x" || isNil "_y") exitWith {}; +(_ui displayCtrl 1021) ctrlSetPosition [ + SafeZoneX + (safezoneW * _x) - (10 * (safezoneW / 64)), + SafeZoneY + (safezoneH * _y) - (10 * (safezoneH / 40)) +]; +(_ui displayCtrl 1022) ctrlSetPosition [ + SafeZoneX + (safezoneW * _x) - (10 * (safezoneW / 64)), + SafeZoneY + (safezoneH * _y) - (10 * (safezoneH / 40)) +]; +(_ui displayCtrl 1021) ctrlCommit 0; +(_ui displayCtrl 1022) ctrlCommit 0; +(_ui displayCtrl 1022) ctrlShow (!isNil {itc_land_spike_lockInformation # 0}); +(_ui displayCtrl 1016) ctrlShow (isNil {itc_land_spike_lockInformation # 0}); diff --git a/addons/ITCExpansionSpike/functions/fn_fired.sqf b/addons/ITCExpansionSpike/functions/fn_fired.sqf new file mode 100644 index 0000000..41e5463 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_fired.sqf @@ -0,0 +1,22 @@ +/* + * itc_land_spike_fnc_fired + */ + +params ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile", "_gunner"]; +//player addmagazine _magazine; +itc_land_spike_currentMissile = _projectile; +itc_land_spike_launchTime = cba_missionTime; +itc_land_spike_activationTime = cba_missionTime; +itc_land_spike_wobble = [if (random 1 > 0.5) then [{-1},{1}], 5 + (random 10), (round (random 3)) * 0.25]; +private _viewASL = AGLtoASL positionCameraToWorld [0,0,0]; +private _intersect = [AGLtoASL positionCameraToWorld [0,0,0], _viewASL vectorFromTo (AGLtoASL positionCameraToWorld [0,0,1])] call itc_land_spike_fnc_intersectScreenToWorld; +if (!isNil "_intersect" && {(_intersect distance player) > 500}) then { + itc_land_spike_targetPos = _intersect; + itc_land_spike_targetPosCamera = _intersect; +} else { + private _forward = AGLtoASL (player modelToWorld [0,3000,0]); + itc_land_spike_targetPos = _forward; + itc_land_spike_targetPosCamera = _forward; +}; + +[] call itc_land_spike_fnc_startCamera; diff --git a/addons/ITCExpansionSpike/functions/fn_guidance.sqf b/addons/ITCExpansionSpike/functions/fn_guidance.sqf new file mode 100644 index 0000000..7a2a145 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_guidance.sqf @@ -0,0 +1,30 @@ +/* + * itc_land_spike_fnc_fired + */ +params ["_seekerTargetPos", "_args", "_attackProfileStateParams"]; +_args params ["_firedEH"]; +_firedEH params ["_shooter","","","","","","_projectile"]; +//drop ["\a3\data_f\Cl_basic","","Billboard",1,20,ASLtoAGL itc_land_spike_targetPos,[0,0,0],1,1.275,1.0,0.0,[1],[[1,0,0,1]],[0],0.0,2.0,"","",""];//red fwd +//drop ["\a3\data_f\Cl_basic","","Billboard",1,20,ASLtoAGL itc_land_spike_targetPosCamera,[0,0,0],1,1.275,1.0,0.0,[1],[[0,1,0,1]],[0],0.0,2.0,"","",""];//red fwd +//drop ["\a3\data_f\Cl_basic","","Billboard",1,20,getPos _projectile,[0,0,0],1,1.275,1.0,0.0,[1],[[0,0,1,1]],[0],0.0,2.0,"","",""];//red fwd +private _fullDist = _shooter distance2D itc_land_spike_targetPos; +private _traveledDist = _projectile distance _shooter; +private _progress = _traveledDist / _fullDist; +private _distanceRemaining = (_projectile distance itc_land_spike_targetPos); +private _target = itc_land_spike_targetPos; +private _targetObject = itc_land_spike_lockInformation # 0; +if (!isNil "_targetObject") then { + private _tofRemaining = _distanceRemaining / (vectorMagnitude velocity _projectile); + _target = _target vectorAdd ((velocity _targetObject) vectorMultiply _tofRemaining); +}; +itc_land_spike_targetPos spawn {sleep 0.05; itc_land_spike_targetPosCamera = _this;}; +if (_progress < 0.3) then { + private _vect = [_fullDist, _shooter getDir itc_land_spike_targetPos, 10] call CBA_fnc_polar2vect; + _target = (getPosASL _shooter) vectorAdd _vect; +}; +//systemChat str _distanceRemaining; +if (_distanceRemaining < 200) then { + "filmGrain" ppEffectAdjust [0.5, _distanceRemaining / 100, 1, 1, 1]; + "filmGrain" ppEffectCommit 0; +}; +_target diff --git a/addons/ITCExpansionSpike/functions/fn_handleCameraAiming.sqf b/addons/ITCExpansionSpike/functions/fn_handleCameraAiming.sqf new file mode 100644 index 0000000..dcf9cbf --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_handleCameraAiming.sqf @@ -0,0 +1,22 @@ +/* + * itc_land_spike_fnc_handleCameraAiming + */ +private _traverse = ((-(inputAction "AimLeft")) + (inputAction "AimRight")) * itc_land_spike_traverseModifier; +private _elevate = ((inputAction "AimUp") + (-(inputAction "AimDown"))) * itc_land_spike_traverseModifier; +setMousePosition [5,5]; +if (_traverse == 0 && _elevate == 0) exitWith {}; +if (abs _traverse > 0.1 || abs _elevate > 0.1) then {itc_land_spike_lockInformation = [nil, [0,0,0], nil, [0,0,0]];}; +// systemChat str [abs _traverse, abs _elevate]; +if (!isNil {itc_land_spike_lockInformation # 0}) exitWith {}; +private _originPosition = getPosASL itc_land_spike_currentMissile; +private _vect = _originPosition vectorFromTo itc_land_spike_targetPos; +private _polar = _vect call cba_fnc_vect2polar; +private _newDir = [ + (_polar # 1) + _traverse, + (_polar # 2) + _elevate +]; +private _intersect = [_originPosition, _newDir # 0, _newDir # 1, false] call itc_land_spike_fnc_intersectAtPolar; +// systemchat str ["intersect", _intersect]; +if(!isNil "_intersect") then { + itc_land_spike_targetPos = _intersect; +}; diff --git a/addons/ITCExpansionSpike/functions/fn_handleLock.sqf b/addons/ITCExpansionSpike/functions/fn_handleLock.sqf new file mode 100644 index 0000000..bf308e4 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_handleLock.sqf @@ -0,0 +1,52 @@ +/* + * itc_land_spike_fnc_handleLock + */ + +private _viewASL = AGLtoASL positionCameraToWorld [0,0,0]; +private _viewDir = _viewASL vectorFromTo (AGLtoASL positionCameraToWorld [0,0,1]); +itc_land_spike_lockInformation params ["_lockObject", "_lockPosition", "_lockLostTime", "_originalLockPosition"]; +if (!isNil "itc_land_spike_currentMissile") then { + _viewASL = getPosASL itc_land_spike_currentMissile; + private _viewTarget = if (!isNil "_lockObject") then [{getPosASL _lockObject}, {itc_land_spike_targetPos}]; + _viewDir = _viewASL vectorFromTo _viewTarget; +}; + +private _missileActivationTime = missionNamespace getVariable ["itc_land_spike_activated_" + currentMagazineDetail player, nil]; +if (isNil "_missileActivationTime") then { + missionNamespace setVariable ["itc_land_spike_activated_" + currentMagazineDetail player, cba_missionTime]; +} else { + if (((inputAction "gunElevAuto" > 0) || (inputAction "lockTarget" > 0)) && isNil "_lockObject") then { + //systemChat str ["LASING", cursorTarget]; + private _target = [_viewASL, _viewDir, true] call itc_land_spike_fnc_intersectScreenToWorld; + private _intersect = [_viewASL, _viewDir] call itc_land_spike_fnc_intersectScreenToWorld; + private _targetPos = if (!isNil "_target") then [{_target worldToModelVisual (ASLtoAGL _intersect)}, {[0,0,0]}]; + itc_land_spike_lockInformation = [_target, _targetPos, nil, _targetPos]; + }; +}; + +//systemChat str itc_land_spike_lockInformation; +if (!isNil "_lockObject") then { + private _targetASL = _lockObject modelToWorldVisualWorld _lockPosition; + private _direction = getCameraViewDirection player; + private _vector = _viewASL vectorFromTo _targetASL; + private _angle = acos (_vector vectorDotProduct _viewDir); + private _visibility = [player, "FIRE", _lockObject] checkVisibility [_viewASL, _targetASL]; + if (_visibility < 0.1 && isNil "_lockLostTime") then { + itc_land_spike_lockInformation set [2, cba_missionTime]; + }; + if (!isNil "_lockLostTime") then { + if (_visibility > 0.2) then { + itc_land_spike_lockInformation set [1, _originalLockPosition]; + itc_land_spike_lockInformation set [2, nil]; + } else { + itc_land_spike_lockInformation set [1, _lockPosition vectorAdd [random 0.1, random 0.1, random 0.1]]; + if (cba_missionTime - _lockLostTime > 2) then {itc_land_spike_lockInformation = [nil, [0,0,0], nil, [0,0,0]];}; + }; + }; + //systemChat str _visibility; + if (_angle > 1.5 && isNil "itc_land_spike_currentMissile") then { + itc_land_spike_lockInformation = [nil, [0,0,0], nil, [0,0,0]]; + }; + itc_land_spike_targetPos = _lockObject modelToWorldVisualWorld _lockPosition; + //drop ["\a3\data_f\Cl_basic","","Billboard",1,20,ASLtoAGL itc_land_spike_targetPos,[0,0,0],1,1.275,1.0,0.0,[1],[[0,0,1,1]],[0],0.0,2.0,"","",""];//red fwd +}; diff --git a/addons/ITCExpansionSpike/functions/fn_init.sqf b/addons/ITCExpansionSpike/functions/fn_init.sqf new file mode 100644 index 0000000..a256c02 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_init.sqf @@ -0,0 +1,9 @@ +itc_land_spike_cameraMode = ""; +itc_land_spike_camera = nil; +itc_land_spike_currentMissile = nil; +itc_land_spike_lockInformation = [nil, [0,0,0], nil, [0,0,0]]; +itc_land_spike_traverseModifier = 0.05; +itc_land_spike_launchTime = 0; +itc_land_spike_wobble = [-1, 15, 0.25]; +itc_land_spike_debug = false; +itc_land_spike_ppEffect = false; diff --git a/addons/ITCExpansionSpike/functions/fn_intersectAtPolar.sqf b/addons/ITCExpansionSpike/functions/fn_intersectAtPolar.sqf new file mode 100644 index 0000000..452fabb --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_intersectAtPolar.sqf @@ -0,0 +1,25 @@ +/* + * itc_land_spike_fnc_intersectAtPolar + */ +params ["_origin","_angleX","_angleY", "_object"]; + +scopeName "return"; + +private _vectorIntersect = [1050, _angleX, _angleY] call CBA_fnc_polar2vect; +private _vectorIntersectDir = vectorNormalized _vectorIntersect; + +for "_i" from 0 to 15 step 1 do { + private _startPos = _origin vectorAdd (_vectorIntersectDir vectorMultiply (_i * 1000)); + private _endPos = _startPos vectorAdd _vectorIntersect; + if (_object) then { + private _intersect = lineIntersectsObjs [_startPos, _endPos, (vehicle player)]; + if(count _intersect > 0) then { + (_intersect # 0) breakOut "return"; + }; + } else { + private _intersect = lineIntersectsSurfaces [_startPos, _endPos, (vehicle player)]; + if(count _intersect > 0) then { + (_intersect # 0 # 0) breakOut "return"; + }; + }; +}; diff --git a/addons/ITCExpansionSpike/functions/fn_intersectScreenToWorld.sqf b/addons/ITCExpansionSpike/functions/fn_intersectScreenToWorld.sqf new file mode 100644 index 0000000..ecb512f --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_intersectScreenToWorld.sqf @@ -0,0 +1,10 @@ +/* + * itc_land_spike_fnc_intersectScreenToWorld + */ +params ["_originPosition", "_direction", ["_object", false]]; +if (isNil "_direction") then { + _direction = _originPosition vectorFromTo (AGLtoASL (screenToWorld [0.5,0.5])); +}; +private _vect = _direction; +private _polar = _vect call cba_fnc_vect2polar; +[_originPosition, _polar # 1, _polar # 2, _object] call itc_land_spike_fnc_intersectAtPolar; diff --git a/addons/ITCExpansionSpike/functions/fn_reloaded.sqf b/addons/ITCExpansionSpike/functions/fn_reloaded.sqf new file mode 100644 index 0000000..fa57f90 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_reloaded.sqf @@ -0,0 +1,5 @@ +/* + * itc_land_spike_fnc_reloaded + */ +params ["_unit", "_weapon", "_muzzle", "_newMagazine", "_oldMagazine"]; +//systemChat str _this; diff --git a/addons/ITCExpansionSpike/functions/fn_selectSpike.sqf b/addons/ITCExpansionSpike/functions/fn_selectSpike.sqf new file mode 100644 index 0000000..66bc14d --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_selectSpike.sqf @@ -0,0 +1,39 @@ +/* + * itc_land_spike_fnc_selectSpike + */ + +params ["_display"]; + +[{ + (_this select 0) params ["_display"]; + if (!alive player || isNull _display || currentWeapon player != "tf47_itc_land_spikeLR") exitWith { + [_this select 1] call CBA_fnc_removePerFrameHandler; + }; + + if (itc_land_spike_cameraMode != cameraView) then { + [] call itc_land_spike_fnc_sightViewChanged; + itc_land_spike_cameraMode = cameraView; + }; + + call itc_land_spike_fnc_handleLock; + + if (!isNil "itc_land_spike_currentMissile" && {isNull itc_land_spike_currentMissile}) exitWith { + (uiNamespace getVariable "itc_land_spike_ui") closeDisplay 2; + itc_land_spike_camera cameraEffect ["terminate", "back"]; + camDestroy itc_land_spike_camera; + itc_land_spike_camera = nil; + itc_land_spike_currentMissile = nil; + itc_land_spike_lockInformation = [nil, [0,0,0], nil, [0,0,0]]; + }; + + if (isNil "itc_land_spike_camera" && cameraView == "GUNNER") then { + [_display] call itc_land_spike_fnc_updateSightOverlay; + } else { + if (!isNil "itc_land_spike_camera") then { + [] call itc_land_spike_fnc_handleCameraAiming; + [_display] call itc_land_spike_fnc_cameraUpdate; + }; + }; + + //systemChat str [time, _display, isNull _display, isNil "_display"]; +}, 0, [_display]] call CBA_fnc_addPerFrameHandler; diff --git a/addons/ITCExpansionSpike/functions/fn_sightClosed.sqf b/addons/ITCExpansionSpike/functions/fn_sightClosed.sqf new file mode 100644 index 0000000..25e79a0 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_sightClosed.sqf @@ -0,0 +1,7 @@ +/* + * itc_land_spike_fnc_cameraClosed + */ + +"colorCorrections" ppEffectEnable false; +"filmGrain" ppEffectEnable false; +itc_land_spike_ppEffect = false; diff --git a/addons/ITCExpansionSpike/functions/fn_sightViewChanged.sqf b/addons/ITCExpansionSpike/functions/fn_sightViewChanged.sqf new file mode 100644 index 0000000..4275c0a --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_sightViewChanged.sqf @@ -0,0 +1,18 @@ +/* + * itc_land_spike_fnc_cameraViewChanged + */ + +//systemChat str ["VIEW CHANGED", cameraView]; + +if (cameraView != "GUNNER" && isNil "itc_land_spike_camera") exitWith { + [] call itc_land_spike_fnc_sightClosed; +}; + +"colorCorrections" ppEffectAdjust [0.9, 0.4, 0, [0.9, 0.4, 0, 0], [1, 1, 1, 0], [1, 1, 1, 0]];; +"colorCorrections" ppEffectCommit 0; +"colorCorrections" ppEffectEnable true; + +"filmGrain" ppEffectAdjust [0.5, 2, 1, 1, 1]; +"filmGrain" ppEffectCommit 0; +"filmGrain" ppEffectEnable true; +itc_land_spike_ppEffect = true; diff --git a/addons/ITCExpansionSpike/functions/fn_startCamera.sqf b/addons/ITCExpansionSpike/functions/fn_startCamera.sqf new file mode 100644 index 0000000..3a0dc96 --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_startCamera.sqf @@ -0,0 +1,13 @@ +itc_land_spike_camera = "camera" camCreate (getPos _projectile); +itc_land_spike_camera camSetFov 0.08333; + +//_camera camSetTarget (ASLtoAGL itc_exp_spike_targetPosCamera); +private _polarToTarget = ((getPosASL _projectile) vectorFromTo itc_land_spike_targetPosCamera) call cba_fnc_vect2polar; +//systemChat str ["polar", _polarToTarget]; +itc_land_spike_camera setDir (_polarToTarget # 1); +[itc_land_spike_camera, (_polarToTarget # 2), 0] call bis_fnc_setpitchbank; +itc_land_spike_camera setVectorUP [0,0.5,0]; +//itc_land_spike_camera attachTo [itc_land_spike_currentMissile, [0,1,0]]; +itc_land_spike_camera cameraEffect ["internal", "BACK"]; +findDisplay 46 createDisplay "ITC_Land_SpikeSeeker"; +showCinemaBorder false; diff --git a/addons/ITCExpansionSpike/functions/fn_updateSightOverlay.sqf b/addons/ITCExpansionSpike/functions/fn_updateSightOverlay.sqf new file mode 100644 index 0000000..267594f --- /dev/null +++ b/addons/ITCExpansionSpike/functions/fn_updateSightOverlay.sqf @@ -0,0 +1,22 @@ +params ["_display"]; +private _group = _display displayCtrl 170; +private _boxHidePosition = if (((call CBA_fnc_getFOV) # 0) > 0.1) then [{[22 * (safezoneW / 64),10 * (safezoneH / 40)]}, {[-1,-1]}]; +(_group controlsGroupCtrl 1020) ctrlSetPosition _boxHidePosition; +(_group controlsGroupCtrl 1020) ctrlCommit 0; +(_group controlsGroupCtrl 1011) ctrlSetText (if (currentVisionMode player == 0) then [{"DTV"}, {"HOT"}]); + +itc_land_spike_lockInformation params ["_lockObject", "_lockPosition", "_lockLostTime", "_originalLockPosition"]; +if (!isNil "_lockObject") then { + private _screenPos = worldToScreen (_lockObject modelToWorld _lockPosition); + private _screenPosX = (_screenPos # 0) - safeZoneX; + private _screenPosY = (_screenPos # 1) - safeZoneY; + _screenPosX = _screenPosX - (10 * (SafeZoneW / 64)); + _screenPosY = _screenPosY - (10 * (SafeZoneH / 40)); + (_group controlsGroupCtrl 1021) ctrlSetPosition [_screenPosX, _screenPosY]; + (_group controlsGroupCtrl 1022) ctrlSetPosition [_screenPosX, _screenPosY]; +} else { + (_group controlsGroupCtrl 1021) ctrlSetPosition [22 * (safezoneW / 64),10 * (safezoneH / 40)]; + (_group controlsGroupCtrl 1022) ctrlSetPosition [-1, -1]; +}; +(_group controlsGroupCtrl 1021) ctrlCommit 0; +(_group controlsGroupCtrl 1022) ctrlCommit 0; diff --git a/addons/ITCExpansionSpike/script_component.hpp b/addons/ITCExpansionSpike/script_component.hpp new file mode 100644 index 0000000..64f6cd6 --- /dev/null +++ b/addons/ITCExpansionSpike/script_component.hpp @@ -0,0 +1,14 @@ +#define COMPONENT ITCExpansionSpike +#include "\z\TF47\addons\main\script_mod.hpp" + +#define DEBUG_MODE_FULL +// #define DISABLE_COMPILE_CACHE + +#ifdef DEBUG_ENABLED_DATABASE + #define DEBUG_MODE_FULL +#endif + #ifdef DEBUG_SETTINGS_DATABASE + #define DEBUG_SETTINGS DEBUG_SETTINGS_DATABASE +#endif + +#include "\z\TF47\addons\main\script_macros.hpp" diff --git a/addons/rhs_compat/CfgAmmo.hpp b/addons/LauncherRework/FGM148/CfgAmmo.hpp similarity index 83% rename from addons/rhs_compat/CfgAmmo.hpp rename to addons/LauncherRework/FGM148/CfgAmmo.hpp index de39383..460a664 100644 --- a/addons/rhs_compat/CfgAmmo.hpp +++ b/addons/LauncherRework/FGM148/CfgAmmo.hpp @@ -5,6 +5,7 @@ class CfgAmmo { warheadName = "TandemHEAT"; maxSpeed = 1000; caliber = 75; + hit = 500; }; @@ -12,8 +13,8 @@ class CfgAmmo { class UK3CB_M_Javelin_AT: ACE_Javelin_FGM148 { submunitionAmmo = "tf47_ammo_Penetrator_Javelin"; submunitionDirectionType = "SubmunitionModelDirection"; - submunitionInitialOffset[] = {0,0,-0.1}; - submunitionInitSpeed = 1000; + submunitionInitialOffset[] = {0,0,-0.2}; + submunitionInitSpeed = 1050; submunitionParentSpeedCoef = 0; warheadName = "TandemHEAT"; }; diff --git a/addons/LauncherRework/config.cpp b/addons/LauncherRework/config.cpp index 431e1ff..9585b48 100644 --- a/addons/LauncherRework/config.cpp +++ b/addons/LauncherRework/config.cpp @@ -92,6 +92,7 @@ class TF47_SmokeExplosion { class CfgAmmo { #include "\z\TF47\addons\LauncherRework\M3\CfgAmmo.hpp" + #include "\z\TF47\addons\LauncherRework\FGM148\CfgAmmo.hpp" }; class CfgMagazines { diff --git a/addons/LauncherRework/script_component.hpp b/addons/LauncherRework/script_component.hpp index b4cb345..9b3daff 100644 --- a/addons/LauncherRework/script_component.hpp +++ b/addons/LauncherRework/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT Launchers +#define COMPONENT LauncherRework #include "\z\TF47\addons\main\script_mod.hpp" #define DEBUG_MODE_FULL diff --git a/addons/RHSRework/$PBOPREFIX$ b/addons/RHSRework/$PBOPREFIX$ new file mode 100644 index 0000000..971b8c3 --- /dev/null +++ b/addons/RHSRework/$PBOPREFIX$ @@ -0,0 +1 @@ +z\TF47\addons\RHSRework \ No newline at end of file diff --git a/addons/rhs_compat/CfgMagazines.hpp b/addons/RHSRework/CfgMagazines.hpp similarity index 100% rename from addons/rhs_compat/CfgMagazines.hpp rename to addons/RHSRework/CfgMagazines.hpp diff --git a/addons/rhs_compat/config.cpp b/addons/RHSRework/config.cpp similarity index 75% rename from addons/rhs_compat/config.cpp rename to addons/RHSRework/config.cpp index 9adab68..1a7f10b 100644 --- a/addons/rhs_compat/config.cpp +++ b/addons/RHSRework/config.cpp @@ -5,11 +5,10 @@ class CfgPatches { units[] = {}; weapons[] = {}; requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"A3_Weapons_F","rhsusf_c_weapons","rhsusf_main","rhs_main","uk3cb_baf_weapons_Launchers","rhssaf_c_weapons","rhssaf_m_weapon_g36"}; + requiredAddons[] = {"A3_Weapons_F","rhsusf_c_weapons","rhsusf_main","rhs_main","rhssaf_c_weapons","rhssaf_m_weapon_g36"}; author = "TF47 -Sonic-, Desty, ra.Y"; VERSION_CONFIG; }; }; -#include "CfgAmmo.hpp" #include "CfgMagazines.hpp" \ No newline at end of file diff --git a/addons/itc_compat/script_component.hpp b/addons/RHSRework/script_component.hpp similarity index 91% rename from addons/itc_compat/script_component.hpp rename to addons/RHSRework/script_component.hpp index 72884b9..2e71568 100644 --- a/addons/itc_compat/script_component.hpp +++ b/addons/RHSRework/script_component.hpp @@ -1,4 +1,4 @@ -#define COMPONENT itc_compat +#define COMPONENT RHSRework #include "\z\TF47\addons\main\script_mod.hpp" #define DEBUG_MODE_FULL diff --git a/addons/SimpleSuppress/stringtable.xml b/addons/SimpleSuppress/stringtable.xml index 9c939f3..410982f 100644 --- a/addons/SimpleSuppress/stringtable.xml +++ b/addons/SimpleSuppress/stringtable.xml @@ -1,7 +1,7 @@ - + https://github.com/SzwedzikPL/SimpleSuppress https://github.com/SzwedzikPL/SimpleSuppress https://github.com/SzwedzikPL/SimpleSuppress @@ -17,7 +17,7 @@ https://github.com/SzwedzikPL/SimpleSuppress https://github.com/SzwedzikPL/SimpleSuppress - + TF47 Simple Suppress TF47 Simple Suppress TF47 Simple Suppress @@ -35,85 +35,85 @@ - + Overlay opacity Nieprzeźroczystość nakładki Интенсивность эффекта подавления Die Deckkraft des Overlays - + Suppression overlay opacity, the higher the value the more visible will be the supression effect. Nieprzeźroczystość nakładki efektu przygwożdżenia, im większa wartość tym bardziej widoczny efekt. Непрозрачность эффекта при подавлении. Die Deckraft des Overlays bestimmt wie stark der Niederhaltungseffekt sichtbar ist. - + Текстура эффекта Overlay texture type Overlay-Textur - + Уровень темноты текстуры наложения. Более темная текстура означает, что при подавлении экран будет затемняться интенсивнее Level of darkness of overlay texture. Darker texture means more screen will be covered with overlay when suppressed. Helligkeitsstufe der Overlay-Texture. Eine dunklere Texture bedeutet das mehr Bildschirmoberfläche bei Niederhaltung davon bedeckt wird. - + Светлая Light Hell - + Средняя Medium Mittel - + Тёмная Dark Dunkel - + Overlay fadeout time Czas zanikania nakładki Время затухания эффекта Ausklingzeit des Effekts - + Suppression overlay fadeout time in seconds Czas zanikania nakłądki efektu przygwożdżenia podany w sekundach Время затухания эффекта подавления в секундах Die Ausklingzeit des Effekts in Sekunden. - + Projectile max distance Maksymalny dystans od pocisku Максимальная дистанция до снаряда Maximale Entfernung zum Projektil - + Max distance from passing projectile in meters. Projectiles passing at larger distance won't be taken into account. Maksymalny dystans od przelatującego pocisku w metrach. Pociski przelatujące na większym dystansie nie będą brane pod uwagę. Максимальное расстояние пролетающего снаряда. Снаряды, пролетающие на большем расстоянии не будут создавать эффект подавления. Maximale Entfernung vom vorbeifliegenden Projektil in Metern. Projektile die in größerer Entfernung vorbeifliegenden werden nicht berücksichtigt. - + Min distance from shooter Minimalny dystans od strzelca Минимальная дистанция до стрелка Kleinste Entfernung vom Schützen - + Min distance from shooter in meters. This option can be used to disable effect in CQB situations, 0 to disable min distance. Minimalny dystans od strzelca w metrach. Za pomocą tej opcji można wyłączyć efekt przygwożdżenia podczas walki na bliski dystanc, 0 aby wyłaczyć. Минимальная дистанция до стрелка в метрах. Данная опция может использоваться для отключения в случаях боя в ограниченном пространстве. Значение 0 отключает опцию. Kleinste Entfernung vom Schützen in Metern. Diese Option kann verwendet werden, um den Effekt in Häuserkämpfen zu deaktivieren. Ein wert von 0 deaktiviert den Mindestabstand. - + Проверка прямой видимости снарядов Check line of sight Fluchtlinie - + При включении проверяет видимость снаряда персонажем игрока. Игнорируются снаряды пролетающие за укрытием (стенами, забором и т.д) When enabled, checks line of sight between player's eyes and passing projectile, ignoring projectiles passing behind cover, walls etc. Wenn aktiviert, wird die Fluchlinie zwischen den Augen des Spielers und des vorbeifliegenden Projektils überprüft. Somit wird sichergestellt, dass Projektile hinter Objekten ignoriert werden. diff --git a/addons/hellfires/$PBOPREFIX$ b/addons/hellfires/$PBOPREFIX$ deleted file mode 100644 index bf41b44..0000000 --- a/addons/hellfires/$PBOPREFIX$ +++ /dev/null @@ -1 +0,0 @@ -z\TF47\addons\hellfires \ No newline at end of file diff --git a/addons/itc_compat/$PBOPREFIX$ b/addons/itc_compat/$PBOPREFIX$ deleted file mode 100644 index b1fa299..0000000 --- a/addons/itc_compat/$PBOPREFIX$ +++ /dev/null @@ -1 +0,0 @@ -z\TF47\addons\itc_compat \ No newline at end of file diff --git a/addons/itc_compat/CfgITCLandBalistics.hpp b/addons/itc_compat/CfgITCLandBalistics.hpp deleted file mode 100644 index 4f46756..0000000 --- a/addons/itc_compat/CfgITCLandBalistics.hpp +++ /dev/null @@ -1,29 +0,0 @@ -class itc_land_ballistics { - class batteryTypes { - class RHS_M109_M284 { - displayName = "M109A6 - 155mmm Howitzer"; - type = "cannon"; - ammunition[] = { - "itc_land_m109hex", - "itc_land_m109icm", - - "itc_land_m109smo", - "itc_land_m109ill", - - "itc_land_m109mat", - "itc_land_m109map", - - "itc_land_m109pgm", - "itc_land_m109icmpgm", - - "itc_land_m109lgm", - "itc_land_m109lgmat", - - "itc_land_m109ext", - "itc_land_m109fal" - }; - - weaponClass = "itc_land_rhs_weap_m284"; - }; - }; -}; \ No newline at end of file diff --git a/addons/main/script_version.hpp b/addons/main/script_version.hpp index c0f116a..80a946a 100644 --- a/addons/main/script_version.hpp +++ b/addons/main/script_version.hpp @@ -1,4 +1,4 @@ #define MAJOR 0 #define MINOR 5 -#define PATCH 2 +#define PATCH 3 #define BUILD 0 diff --git a/addons/rhs_compat/$PBOPREFIX$ b/addons/rhs_compat/$PBOPREFIX$ deleted file mode 100644 index d93ee8b..0000000 --- a/addons/rhs_compat/$PBOPREFIX$ +++ /dev/null @@ -1 +0,0 @@ -z\TF47\addons\rhs_compat \ No newline at end of file diff --git a/addons/rhs_compat/CfgEventHandlers.hpp b/addons/rhs_compat/CfgEventHandlers.hpp deleted file mode 100644 index e90bed4..0000000 --- a/addons/rhs_compat/CfgEventHandlers.hpp +++ /dev/null @@ -1,15 +0,0 @@ -class Extended_PreStart_EventHandlers { - class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preStart)); - }; -}; -class Extended_PreInit_EventHandlers { - class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); - }; -}; -class Extended_PostInit_EventHandlers { - class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); - }; -}; diff --git a/addons/rhs_compat/XEH_PREP.hpp b/addons/rhs_compat/XEH_PREP.hpp deleted file mode 100644 index e69de29..0000000 diff --git a/addons/rhs_compat/XEH_postInit.sqf b/addons/rhs_compat/XEH_postInit.sqf deleted file mode 100644 index 84f2529..0000000 --- a/addons/rhs_compat/XEH_postInit.sqf +++ /dev/null @@ -1 +0,0 @@ -#include "script_component.hpp" \ No newline at end of file diff --git a/addons/rhs_compat/XEH_preInit.sqf b/addons/rhs_compat/XEH_preInit.sqf deleted file mode 100644 index ecb5d0c..0000000 --- a/addons/rhs_compat/XEH_preInit.sqf +++ /dev/null @@ -1,8 +0,0 @@ -#include "script_component.hpp" -ADDON = false; - -PREP_RECOMPILE_START; -#include "XEH_PREP.hpp" -PREP_RECOMPILE_END; - -ADDON = true; diff --git a/addons/rhs_compat/XEH_preStart.sqf b/addons/rhs_compat/XEH_preStart.sqf deleted file mode 100644 index a51262a..0000000 --- a/addons/rhs_compat/XEH_preStart.sqf +++ /dev/null @@ -1,2 +0,0 @@ -#include "script_component.hpp" -#include "XEH_PREP.hpp"