From 7568e0881dabcf6170a4a0711843a6a980ea2145 Mon Sep 17 00:00:00 2001 From: johnb432 <58661205+johnb432@users.noreply.github.com> Date: Tue, 13 Aug 2024 09:04:35 +0200 Subject: [PATCH 1/3] Improve explosives naming --- addons/explosives/CfgVehicles.hpp | 28 +++++++++--------- .../compat_explosives/CfgVehicles.hpp | 29 +++++++++++++++++++ .../compat_explosives/config.cpp | 21 ++++++++++++++ .../compat_explosives/script_component.hpp | 3 ++ 4 files changed, 67 insertions(+), 14 deletions(-) create mode 100644 addons/realisticnames/compat_explosives/CfgVehicles.hpp create mode 100644 addons/realisticnames/compat_explosives/config.cpp create mode 100644 addons/realisticnames/compat_explosives/script_component.hpp diff --git a/addons/explosives/CfgVehicles.hpp b/addons/explosives/CfgVehicles.hpp index 91a708beb87..289e30f9f22 100644 --- a/addons/explosives/CfgVehicles.hpp +++ b/addons/explosives/CfgVehicles.hpp @@ -106,7 +106,7 @@ class CfgVehicles { }; class ACE_Explosives_Place_DemoCharge: ACE_Explosives_Place { - displayName = "Demo Charge"; + displayName = "$STR_A3_cfgMagazines_DemoCharge0"; model = "\A3\Weapons_F\explosives\c4_charge_small_d"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -115,15 +115,15 @@ class CfgVehicles { }; }; class ACE_Explosives_Place_APERSBoundingMine: ACE_Explosives_Place { - displayName = "APERS Bounding Mine"; + displayName = "$STR_A3_cfgMagazines_BouncingMineRangeMagazine0"; model = "\A3\Weapons_F\explosives\mine_AP_bouncing"; }; class ACE_Explosives_Place_APERSMine: ACE_Explosives_Place { - displayName = "APERS Mine"; + displayName = "$STR_A3_cfgMagazines_ClassicMineRangeMagazine0"; model = "\A3\Weapons_F\explosives\mine_ap"; }; class ACE_Explosives_Place_APERSTripwireMine: ACE_Explosives_Place { - displayName = "APERS Tripwire Mine"; + displayName = "$STR_A3_cfgMagazines_ClassicMineWireMagazine0"; model = "\A3\Weapons_F\explosives\mine_AP_tripwire"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -133,12 +133,12 @@ class CfgVehicles { }; class ACE_Explosives_Place_ATMine: ACE_Explosives_Place { - displayName = "AT Mine"; + displayName = "$STR_A3_CfgMagazines_Mine0"; model = "\A3\Weapons_f\Explosives\mine_at"; }; class ACE_Explosives_Place_Claymore: ACE_Explosives_Place { - displayName = "Claymore"; + displayName = "$STR_A3_cfgMagazines_DirectionalMineRemoteMagazine0"; model = "\A3\Weapons_F\explosives\mine_AP_miniclaymore"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -148,7 +148,7 @@ class CfgVehicles { }; class ACE_Explosives_Place_SatchelCharge: ACE_Explosives_Place { - displayName = "Satchel Charge"; + displayName = "$STR_A3_cfgMagazines_PipeBomb0"; model = "\A3\Weapons_F\Explosives\satchel"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -159,7 +159,7 @@ class CfgVehicles { // Orange DLC: class ACE_Explosives_Place_APERSMineDispenser: ACE_Explosives_Place { - displayName = "APERSMineDispenser"; + displayName = "$STR_A3_CfgMagazines_APERSMineDispenser_Mag0"; model = "\A3\Weapons_F_Orange\Explosives\APERSmineDispenser"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -168,7 +168,7 @@ class CfgVehicles { }; }; class ACE_Explosives_Place_TrainingMine: ACE_Explosives_Place { - displayName = "TrainingMine"; + displayName = "$STR_A3_CfgMagazines_TrainingMine_Mag0"; model = "\A3\Weapons_F_Orange\Explosives\TrainingMine_F"; class ACE_Actions: ACE_Actions { class ACE_MainActions: ACE_MainActions { @@ -179,28 +179,28 @@ class CfgVehicles { class ACE_Explosives_Place_SLAM: ACE_Explosives_Place { - displayName = "SLAM"; + displayName = "$STR_A3_cfgMagazines_DirectionalMineRangeMagazine0"; model = "\A3\Weapons_F\Explosives\mine_SLAM_directional"; }; // IEDs class ACE_Explosives_Place_IEDUrbanBig: ACE_Explosives_Place { - displayName = "IED Urban Big"; + displayName = "$STR_A3_CfgVehicles_IEDUrbanBig_F"; model = "\A3\Weapons_F\Explosives\IED_urban_big"; }; class ACE_Explosives_Place_IEDLandBig: ACE_Explosives_Place { - displayName = "IED Land Big"; + displayName = "$STR_A3_CfgVehicles_IEDLandBig_F"; model = "\A3\Weapons_F\Explosives\IED_land_big"; }; class ACE_Explosives_Place_IEDUrbanSmall: ACE_Explosives_Place { - displayName = "IED Urban Small"; + displayName = "$STR_A3_CfgVehicles_IEDUrbanSmall_F"; model = "\A3\Weapons_F\Explosives\IED_urban_small"; }; class ACE_Explosives_Place_IEDLandSmall: ACE_Explosives_Place { - displayName = "IED Land Small"; + displayName = "$STR_A3_CfgVehicles_IEDLandSmall_F"; model = "\A3\Weapons_F\Explosives\IED_land_small"; }; diff --git a/addons/realisticnames/compat_explosives/CfgVehicles.hpp b/addons/realisticnames/compat_explosives/CfgVehicles.hpp new file mode 100644 index 00000000000..e22068161a8 --- /dev/null +++ b/addons/realisticnames/compat_explosives/CfgVehicles.hpp @@ -0,0 +1,29 @@ +class CfgVehicles { + class ACE_Explosives_Place; + class ACE_Explosives_Place_DemoCharge: ACE_Explosives_Place { + displayName = CSTRING(DemoCharge_Name); + }; + class ACE_Explosives_Place_APERSBoundingMine: ACE_Explosives_Place { + displayName = CSTRING(APERSBoundingMine_Name); + }; + class ACE_Explosives_Place_APERSMine: ACE_Explosives_Place { + displayName = CSTRING(APERSMine_Name); + }; + class ACE_Explosives_Place_APERSTripwireMine: ACE_Explosives_Place { + displayName = CSTRING(APERSTripwireMine_Name); + }; + class ACE_Explosives_Place_ATMine: ACE_Explosives_Place { + displayName = CSTRING(ATMine_Name); + }; + class ACE_Explosives_Place_Claymore: ACE_Explosives_Place { + displayName = CSTRING(Claymore_Name); + }; + class ACE_Explosives_Place_SatchelCharge: ACE_Explosives_Place { + displayName = CSTRING(SatchelCharge_Name); + }; + + // Orange DLC + class ACE_Explosives_Place_SLAM: ACE_Explosives_Place { + displayName = CSTRING(SLAM_Name); + }; +}; diff --git a/addons/realisticnames/compat_explosives/config.cpp b/addons/realisticnames/compat_explosives/config.cpp new file mode 100644 index 00000000000..b4233176814 --- /dev/null +++ b/addons/realisticnames/compat_explosives/config.cpp @@ -0,0 +1,21 @@ +#include "script_component.hpp" + +class CfgPatches { + class SUBADDON { + name = COMPONENT_NAME; + units[] = {}; + weapons[] = {}; + requiredVersion = REQUIRED_VERSION; + requiredAddons[] = {QUOTE(ADDON), "ace_explosives"}; + skipWhenMissingDependencies = 1; + author = ECSTRING(common,ACETeam); + authors[] = {}; + url = ECSTRING(main,URL); + VERSION_CONFIG; + + // this prevents any patched class from requiring this addon + addonRootClass = "A3_Characters_F"; + }; +}; + +#include "CfgVehicles.hpp" diff --git a/addons/realisticnames/compat_explosives/script_component.hpp b/addons/realisticnames/compat_explosives/script_component.hpp new file mode 100644 index 00000000000..a697aad7f3b --- /dev/null +++ b/addons/realisticnames/compat_explosives/script_component.hpp @@ -0,0 +1,3 @@ +#define SUBCOMPONENT explosives +#define SUBCOMPONENT_BEAUTIFIED Explosives +#include "..\script_component.hpp" From 8cffe6d3d8b5b0c493a11dcce3f233f2f4312b39 Mon Sep 17 00:00:00 2001 From: johnb432 <58661205+johnb432@users.noreply.github.com> Date: Tue, 13 Aug 2024 09:35:19 +0200 Subject: [PATCH 2/3] Move all ACE explosives into compat --- addons/realisticnames/CfgMagazines.hpp | 6 ------ addons/realisticnames/compat_explosives/CfgMagazines.hpp | 8 ++++++++ addons/realisticnames/compat_explosives/config.cpp | 1 + 3 files changed, 9 insertions(+), 6 deletions(-) create mode 100644 addons/realisticnames/compat_explosives/CfgMagazines.hpp diff --git a/addons/realisticnames/CfgMagazines.hpp b/addons/realisticnames/CfgMagazines.hpp index be7ce2b2a51..dc5beec603c 100644 --- a/addons/realisticnames/CfgMagazines.hpp +++ b/addons/realisticnames/CfgMagazines.hpp @@ -390,12 +390,6 @@ class CfgMagazines { class DemoCharge_Remote_Mag: SatchelCharge_Remote_Mag { displayName = CSTRING(DemoCharge_Name); }; - class ACE_SatchelCharge_Remote_Mag_Throwable: CA_Magazine { - displayName = CSTRING(SatchelChargeThrowable_Name); - }; - class ACE_DemoCharge_Remote_Mag_Throwable: ACE_SatchelCharge_Remote_Mag_Throwable { - displayName = CSTRING(DemoChargeThrowable_Name); - }; // hand grenades class HandGrenade: CA_Magazine { diff --git a/addons/realisticnames/compat_explosives/CfgMagazines.hpp b/addons/realisticnames/compat_explosives/CfgMagazines.hpp new file mode 100644 index 00000000000..c795fe6a78b --- /dev/null +++ b/addons/realisticnames/compat_explosives/CfgMagazines.hpp @@ -0,0 +1,8 @@ +class CfgMagazines { + class ACE_SatchelCharge_Remote_Mag_Throwable: CA_Magazine { + displayName = CSTRING(SatchelChargeThrowable_Name); + }; + class ACE_DemoCharge_Remote_Mag_Throwable: ACE_SatchelCharge_Remote_Mag_Throwable { + displayName = CSTRING(DemoChargeThrowable_Name); + }; +}; diff --git a/addons/realisticnames/compat_explosives/config.cpp b/addons/realisticnames/compat_explosives/config.cpp index b4233176814..208bc7e791f 100644 --- a/addons/realisticnames/compat_explosives/config.cpp +++ b/addons/realisticnames/compat_explosives/config.cpp @@ -18,4 +18,5 @@ class CfgPatches { }; }; +#include "CfgMagazines.hpp" #include "CfgVehicles.hpp" From 9da62b51caaf8f062632e7bc01a7d1b142fb90ea Mon Sep 17 00:00:00 2001 From: johnb432 <58661205+johnb432@users.noreply.github.com> Date: Tue, 13 Aug 2024 09:35:48 +0200 Subject: [PATCH 3/3] Update CfgMagazines.hpp --- addons/realisticnames/compat_explosives/CfgMagazines.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/realisticnames/compat_explosives/CfgMagazines.hpp b/addons/realisticnames/compat_explosives/CfgMagazines.hpp index c795fe6a78b..41a19345dbe 100644 --- a/addons/realisticnames/compat_explosives/CfgMagazines.hpp +++ b/addons/realisticnames/compat_explosives/CfgMagazines.hpp @@ -1,4 +1,5 @@ class CfgMagazines { + class CA_Magazine; class ACE_SatchelCharge_Remote_Mag_Throwable: CA_Magazine { displayName = CSTRING(SatchelChargeThrowable_Name); };