From ece1031c4dec8670260cdc4b1e87d6d56a477847 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 3 Apr 2019 11:40:14 -0500 Subject: [PATCH] RHS Compat - Add 2 round hellfire to pylon options (#6893) * RHS Compat - Add 2 rnd hellfire pylon Close #5957 * change magwell name * gvar->addon --- addons/hellfire/CfgMagazineWells.hpp | 4 ++++ addons/hellfire/CfgWeapons.hpp | 5 +++-- addons/hellfire/config.cpp | 1 + optionals/compat_rhs_usf3/CfgMagazineWells.hpp | 8 ++++++++ optionals/compat_rhs_usf3/CfgMagazines.hpp | 13 +++++++++++++ optionals/compat_rhs_usf3/config.cpp | 1 + 6 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 addons/hellfire/CfgMagazineWells.hpp create mode 100644 optionals/compat_rhs_usf3/CfgMagazineWells.hpp diff --git a/addons/hellfire/CfgMagazineWells.hpp b/addons/hellfire/CfgMagazineWells.hpp new file mode 100644 index 0000000000..5077d2faa6 --- /dev/null +++ b/addons/hellfire/CfgMagazineWells.hpp @@ -0,0 +1,4 @@ +class CfgMagazineWells { + class GVAR(K) {}; + class GVAR(N) {}; +}; diff --git a/addons/hellfire/CfgWeapons.hpp b/addons/hellfire/CfgWeapons.hpp index 1d7f167aad..b040f67d1d 100644 --- a/addons/hellfire/CfgWeapons.hpp +++ b/addons/hellfire/CfgWeapons.hpp @@ -6,7 +6,7 @@ class CfgWeapons { EGVAR(laser,canSelect) = 1; // can ace_laser lock (allows switching laser code) EGVAR(laser,showHud) = 1; // show attack profile / lock on hud magazines[] = {"6Rnd_ACE_Hellfire_AGM114K", "PylonMissile_1Rnd_ACE_Hellfire_AGM114K", "PylonRack_1Rnd_ACE_Hellfire_AGM114K", "PylonRack_3Rnd_ACE_Hellfire_AGM114K", "PylonRack_4Rnd_ACE_Hellfire_AGM114K"}; - + magazineWell[] = {QGVAR(K)}; autoFire = 0; canLock = 0; weaponLockSystem = 0; @@ -14,7 +14,7 @@ class CfgWeapons { lockedTargetSound[] = {"",0,1}; soundFly[] = {"A3\Sounds_F\weapons\Rockets\rocket_fly_1",1,1.1,700}; nameSound = "MissileLauncher"; - sounds[] = {"StandardSound"}; + sounds[] = {"StandardSound"}; class StandardSound { begin1[] = {"A3\Sounds_F\weapons\Rockets\missile_1",1.12202,1.3,1000}; soundBegin[] = {"begin1",1}; @@ -27,5 +27,6 @@ class CfgWeapons { class GVAR(launcher_N): GVAR(launcher) { displayName = "AGM-114N Hellfire II"; magazines[] = {"6Rnd_ACE_Hellfire_AGM114N", "PylonMissile_1Rnd_ACE_Hellfire_AGM114N", "PylonRack_1Rnd_ACE_Hellfire_AGM114N", "PylonRack_3Rnd_ACE_Hellfire_AGM114N", "PylonRack_4Rnd_ACE_Hellfire_AGM114N"}; + magazineWell[] = {QGVAR(N)}; }; }; diff --git a/addons/hellfire/config.cpp b/addons/hellfire/config.cpp index 8df1594612..911e016d7f 100644 --- a/addons/hellfire/config.cpp +++ b/addons/hellfire/config.cpp @@ -18,5 +18,6 @@ class CfgPatches { #include "CfgAmmo.hpp" #include "CfgEventHandlers.hpp" #include "CfgMagazines.hpp" +#include "CfgMagazineWells.hpp" #include "CfgVehicles.hpp" #include "CfgWeapons.hpp" diff --git a/optionals/compat_rhs_usf3/CfgMagazineWells.hpp b/optionals/compat_rhs_usf3/CfgMagazineWells.hpp new file mode 100644 index 0000000000..7ee767c4a9 --- /dev/null +++ b/optionals/compat_rhs_usf3/CfgMagazineWells.hpp @@ -0,0 +1,8 @@ +class CfgMagazineWells { + class ace_hellfire_K { + ADDON[] = {QGVAR(pylon_mag_2rnd_hellfire_k)}; + }; + class ace_hellfire_N { + ADDON[] = {GVAR(pylon_mag_2rnd_hellfire_n)}; + }; +}; diff --git a/optionals/compat_rhs_usf3/CfgMagazines.hpp b/optionals/compat_rhs_usf3/CfgMagazines.hpp index 9e595fddfb..1f692792f0 100644 --- a/optionals/compat_rhs_usf3/CfgMagazines.hpp +++ b/optionals/compat_rhs_usf3/CfgMagazines.hpp @@ -23,4 +23,17 @@ class cfgMagazines { EGVAR(overpressure,range) = 0; EGVAR(overpressure,damage) = 0; }; + + class rhs_mag_AGM114K_2; + class GVAR(pylon_mag_2rnd_hellfire_k): rhs_mag_AGM114K_2 { + displayName = "2x AGM-114K [ACE]"; + pylonWeapon = "ace_hellfire_launcher"; + ammo = "ACE_Hellfire_AGM114K"; + }; + class GVAR(pylon_mag_2rnd_hellfire_n): rhs_mag_AGM114K_2 { + displayName = "2x AGM-114N [ACE]"; + pylonWeapon = "ace_hellfire_launcher_N"; + ammo = "ACE_Hellfire_AGM114N"; + }; + }; diff --git a/optionals/compat_rhs_usf3/config.cpp b/optionals/compat_rhs_usf3/config.cpp index 5847a2ac40..59aaa625bd 100644 --- a/optionals/compat_rhs_usf3/config.cpp +++ b/optionals/compat_rhs_usf3/config.cpp @@ -17,6 +17,7 @@ class CfgPatches { #include "CfgAmmo.hpp" #include "CfgEventHandlers.hpp" #include "CfgMagazines.hpp" +#include "CfgMagazineWells.hpp" #include "CfgWeapons.hpp" #include "CfgVehicles.hpp" #include "CfgGlasses.hpp"