From 0321545098e0573b1e35536e9b2bc3d81bd20dd5 Mon Sep 17 00:00:00 2001 From: Dystopian Date: Fri, 28 Jul 2023 12:47:23 +0300 Subject: [PATCH] Rearm - Add enable setting (#8067) * Add enable setting * Update test * Optimize eden macro * Fix bad command name in eden * Apply suggestions from code review Co-authored-by: jonpas * Cleanup unused argument * Handle RHS config * Optimize init function a little * Improve macro Co-authored-by: jonpas * compats and leftovers * function header (sorry jonpas) * add enabled check to initSupplyVehicle * use toString * fix validate * inheritance cleanup --------- Co-authored-by: jonpas Co-authored-by: LinkIsGrim --- addons/rearm/Cfg3DEN.hpp | 4 +- addons/rearm/CfgVehicles.hpp | 21 ++------ addons/rearm/XEH_postInit.sqf | 52 ++++++++++++------- addons/rearm/dev/test_debugConfigs.sqf | 13 +++-- .../rearm/functions/fnc_initSupplyVehicle.sqf | 12 ++++- addons/rearm/functions/fnc_isSource.sqf | 10 ++-- addons/rearm/functions/fnc_makeSource.sqf | 6 ++- addons/rearm/initSettings.sqf | 20 +++++-- optionals/compat_gm/CfgVehicles.hpp | 1 - optionals/compat_gm/config.cpp | 2 +- optionals/compat_rhs_afrf3/CfgVehicles.hpp | 9 ++-- optionals/compat_rhs_afrf3/config.cpp | 2 +- optionals/compat_rhs_usf3/CfgVehicles.hpp | 5 -- optionals/compat_rhs_usf3/config.cpp | 3 +- optionals/compat_sog/CfgVehicles/wheeled.hpp | 2 - 15 files changed, 88 insertions(+), 74 deletions(-) diff --git a/addons/rearm/Cfg3DEN.hpp b/addons/rearm/Cfg3DEN.hpp index 05581e7206..e5e52dbcd0 100644 --- a/addons/rearm/Cfg3DEN.hpp +++ b/addons/rearm/Cfg3DEN.hpp @@ -1,6 +1,6 @@ +#define VANILLA_REARMCARGO (if (getAmmoCargo _this > 0) then {getAmmoCargo _this} else {-1}) #define GET_NUMBER(config,default) (if (isNumber (config)) then {getNumber (config)} else {default}) -#define DEFAULT_REARMCARGO GET_NUMBER(configOf _this >> QQGVAR(defaultSupply),-1) - +#define DEFAULT_REARMCARGO GET_NUMBER(configOf _this >> 'GVAR(defaultSupply)',VANILLA_REARMCARGO) class Cfg3DEN { class Object { diff --git a/addons/rearm/CfgVehicles.hpp b/addons/rearm/CfgVehicles.hpp index 221b01b249..9d36d5baae 100644 --- a/addons/rearm/CfgVehicles.hpp +++ b/addons/rearm/CfgVehicles.hpp @@ -102,66 +102,51 @@ class CfgVehicles { class Truck_03_base_F; class O_Truck_03_ammo_F: Truck_03_base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class Truck_02_base_F; class Truck_02_Ammo_base_F: Truck_02_base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class B_Truck_01_mover_F; class B_Truck_01_ammo_F: B_Truck_01_mover_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class B_APC_Tracked_01_base_F; class B_APC_Tracked_01_CRV_F: B_APC_Tracked_01_base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class Heli_Transport_04_base_F; class O_Heli_Transport_04_ammo_F: Heli_Transport_04_base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class Pod_Heli_Transport_04_base_F; class Land_Pod_Heli_Transport_04_ammo_F: Pod_Heli_Transport_04_base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; class Slingload_01_Base_F; class B_Slingload_01_Ammo_F: Slingload_01_Base_F { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; - class ReammoBox_F; - class NATO_Box_Base: ReammoBox_F {}; + class NATO_Box_Base; class Box_NATO_AmmoVeh_F: NATO_Box_Base { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; - class EAST_Box_Base: ReammoBox_F {}; + class EAST_Box_Base; class Box_East_AmmoVeh_F: EAST_Box_Base { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; - class IND_Box_Base: ReammoBox_F {}; + class IND_Box_Base; class Box_IND_AmmoVeh_F: IND_Box_Base { - transportAmmo = 0; GVAR(defaultSupply) = 1200; }; - class Box_IND_AmmoOrd_F; - class Box_IDAP_AmmoOrd_F: Box_IND_AmmoOrd_F { - transportAmmo = 0; // not sure why this one has 240 - }; // Dummy Vehicles class ThingX; diff --git a/addons/rearm/XEH_postInit.sqf b/addons/rearm/XEH_postInit.sqf index 3a6d72fcbe..f156fb71d6 100644 --- a/addons/rearm/XEH_postInit.sqf +++ b/addons/rearm/XEH_postInit.sqf @@ -1,33 +1,45 @@ #include "script_component.hpp" +GVAR(hardpointGroupsCache) = [] call CBA_fnc_createNamespace; GVAR(configTypesAdded) = []; -["CBA_settingsInitialized", { - TRACE_2("settingsInit",GVAR(level),GVAR(supply)); - ["LandVehicle", "Init", {_this call FUNC(initSupplyVehicle)}, true, ["StaticWeapon"], true] call CBA_fnc_addClassEventHandler; - ["ReammoBox_F", "Init", {_this call FUNC(initSupplyVehicle)}, true, [], true] call CBA_fnc_addClassEventHandler; -}] call CBA_fnc_addEventHandler; +GVAR(magazineNameCache) = [] call CBA_fnc_createNamespace; +GVAR(originalMagazineNames) = []; -["ace_unconscious", LINKFUNC(handleUnconscious)] call CBA_fnc_addEventHandler; [QGVAR(initSupplyVehicle), { TRACE_1("initSupplyVehicle EH",_this); // Warning: this can run before settings are init [FUNC(initSupplyVehicle), _this] call EFUNC(common,runAfterSettingsInit); }] call CBA_fnc_addEventHandler; -["vehicle", { - params ["_unit"]; - [_unit] call FUNC(dropAmmo); -}] call CBA_fnc_addPlayerEventHandler; +["CBA_settingsInitialized", { + TRACE_3("settingsInit",GVAR(enabled),GVAR(level),GVAR(supply)); -if (isServer) then { - addMissionEventHandler ["HandleDisconnect", {params ["_unit"]; [_unit] call FUNC(dropAmmo)}]; -}; + // need these events before enabled check for zeus rearm + [QGVAR(rearmEntireVehicleSuccessEH), LINKFUNC(rearmEntireVehicleSuccess)] call CBA_fnc_addEventHandler; + [QGVAR(rearmEntireVehicleSuccessLocalEH), LINKFUNC(rearmEntireVehicleSuccessLocal)] call CBA_fnc_addEventHandler; + [QGVAR(makeDummyEH), LINKFUNC(makeDummy)] call CBA_fnc_addEventHandler; + [QGVAR(rearmSuccessEH), LINKFUNC(rearmSuccess)] call CBA_fnc_addEventHandler; + [QGVAR(rearmSuccessLocalEH), LINKFUNC(rearmSuccessLocal)] call CBA_fnc_addEventHandler; -[QGVAR(makeDummyEH), LINKFUNC(makeDummy)] call CBA_fnc_addEventHandler; -[QGVAR(rearmEntireVehicleSuccessEH), LINKFUNC(rearmEntireVehicleSuccess)] call CBA_fnc_addEventHandler; -[QGVAR(rearmEntireVehicleSuccessLocalEH), LINKFUNC(rearmEntireVehicleSuccessLocal)] call CBA_fnc_addEventHandler; -[QGVAR(rearmSuccessEH), LINKFUNC(rearmSuccess)] call CBA_fnc_addEventHandler; -[QGVAR(rearmSuccessLocalEH), LINKFUNC(rearmSuccessLocal)] call CBA_fnc_addEventHandler; + if (!GVAR(enabled)) exitWith {}; + ["AllVehicles", "Init", LINKFUNC(initSupplyVehicle), true, ["Man", "StaticWeapon"], true] call CBA_fnc_addClassEventHandler; + ["ReammoBox_F", "Init", LINKFUNC(initSupplyVehicle), true, [], true] call CBA_fnc_addClassEventHandler; + ["House", "Init", LINKFUNC(initSupplyVehicle), true, [], true] call CBA_fnc_addClassEventHandler; -GVAR(magazineNameCache) = [] call CBA_fnc_createNamespace; -GVAR(originalMagazineNames) = []; + // placed in editor static objects don't trigger init + { + _x call FUNC(initSupplyVehicle); + } forEach allMissionObjects "Static"; + + ["ace_unconscious", LINKFUNC(handleUnconscious)] call CBA_fnc_addEventHandler; + + ["vehicle", { + params ["_unit"]; + [_unit] call FUNC(dropAmmo); + }] call CBA_fnc_addPlayerEventHandler; + + if (isServer) then { + addMissionEventHandler ["HandleDisconnect", {params ["_unit"]; [_unit] call FUNC(dropAmmo)}]; + }; + +}] call CBA_fnc_addEventHandler; diff --git a/addons/rearm/dev/test_debugConfigs.sqf b/addons/rearm/dev/test_debugConfigs.sqf index 8b61bf195f..cbe09c1f17 100644 --- a/addons/rearm/dev/test_debugConfigs.sqf +++ b/addons/rearm/dev/test_debugConfigs.sqf @@ -5,10 +5,17 @@ private _testPass = true; -INFO("Showing CfgVehicles with vanilla transportAmmo"); +INFO("Showing CfgVehicles with vanilla transportAmmo and without XEH"); + +private _badCfgVehicles = toString { + getNumber (_x >> "scope") == 2 + && {getNumber (_x >> "transportAmmo") > 0} + && {!isText (_x >> "EventHandlers" >> "CBA_Extended_EventHandlers" >> "init")} +}; + { - WARNING_2("Type [%1] needs config [transportAmmo: %2]", configName _x, getNumber (_x >> 'transportAmmo')); + diag_log text format ["Class %1: %2 [%3] needs XEH", configName _x, configName inheritsFrom _x, configSourceMod _x]; _testPass = false; -} forEach (configProperties [configFile >> "CfgVehicles", "(isClass _x) && {(getNumber (_x >> 'transportAmmo')) > 0}", true]); +} forEach (_badCfgVehicles configClasses (configFile >> "CfgVehicles")); _testPass diff --git a/addons/rearm/functions/fnc_initSupplyVehicle.sqf b/addons/rearm/functions/fnc_initSupplyVehicle.sqf index e748062e65..efd181388f 100644 --- a/addons/rearm/functions/fnc_initSupplyVehicle.sqf +++ b/addons/rearm/functions/fnc_initSupplyVehicle.sqf @@ -15,16 +15,26 @@ * Public: No */ -if (!hasInterface) exitWith {}; // For now we just add actions, so no need non-clients +if (!GVAR(enabled)) exitWith {}; params ["_vehicle"]; + private _typeOf = typeOf _vehicle; private _configOf = configOf _vehicle; TRACE_2("initSupplyVehicle",_vehicle,_typeOf); +if (local _vehicle && {getAmmoCargo _vehicle > 0}) then { + _vehicle setAmmoCargo 0; +}; + +if (!hasInterface) exitWith {}; // For now we just add actions, so no need non-clients + if (!alive _vehicle) exitWith {}; private _configSupply = getNumber (_configOf >> QGVAR(defaultSupply)); +if (_configSupply == 0) then { + _configSupply = getNumber (_config >> "transportAmmo"); +}; private _isSupplyVehicle = _vehicle getVariable [QGVAR(isSupplyVehicle), false]; private _oldRearmConfig = isClass (_configOf >> "ACE_Actions" >> "ACE_MainActions" >> QGVAR(takeAmmo)); TRACE_3("",_configSupply,_isSupplyVehicle,_oldRearmConfig); diff --git a/addons/rearm/functions/fnc_isSource.sqf b/addons/rearm/functions/fnc_isSource.sqf index 93f45be6a1..fc37d905c5 100644 --- a/addons/rearm/functions/fnc_isSource.sqf +++ b/addons/rearm/functions/fnc_isSource.sqf @@ -4,8 +4,7 @@ * Returns if vehicle or object is a rearm source. * * Arguments: - * 0: target - * 1: check for vanilla rearm vehicle (default: false) + * 0: Target * * Return Value: * None @@ -15,10 +14,7 @@ * * Public: Yes */ -params [ - ["_target", objNull, [objNull]], - ["_testVanillaRearm", false, [false]] - ]; +params [["_target", objNull, [objNull]]]; if ((_target getVariable [QGVAR(currentSupply), 0]) < 0) exitWith {false}; @@ -27,4 +23,4 @@ private _vanillaCargoConfig = getNumber (_vehCfg >> "transportAmmo"); private _rearmCargoConfig = getNumber (_vehCfg >> QGVAR(defaultSupply)); private _supplyVehicle = _target getVariable [QGVAR(isSupplyVehicle), false]; -_rearmCargoConfig > 0 || {_supplyVehicle} || {_testVanillaRearm && _vanillaCargoConfig > 0} +_rearmCargoConfig > 0 || {_supplyVehicle} || {_vanillaCargoConfig > 0} diff --git a/addons/rearm/functions/fnc_makeSource.sqf b/addons/rearm/functions/fnc_makeSource.sqf index 51aa515cdf..3084871efc 100644 --- a/addons/rearm/functions/fnc_makeSource.sqf +++ b/addons/rearm/functions/fnc_makeSource.sqf @@ -41,7 +41,11 @@ private _currentSupply = if (_addToCurrent) then { _source setVariable [QGVAR(currentSupply), _currentSupply + _rearmCargo, true]; -private _rearmCargoConfig = getNumber (configOf _source >> QGVAR(defaultSupply)); +private _config = configOf _source; +private _rearmCargoConfig = getNumber (_config >> QGVAR(defaultSupply)); +if (_rearmCargoConfig == 0) then { + _rearmCargoConfig = getNumber (_config >> "transportAmmo"); +}; // initialize if it's not a config rearm vehicle if (!(_rearmCargoConfig > 0 && _source getVariable [QGVAR(isSupplyVehicle), false])) then { diff --git a/addons/rearm/initSettings.sqf b/addons/rearm/initSettings.sqf index c2d6136bd7..d83ac3c760 100644 --- a/addons/rearm/initSettings.sqf +++ b/addons/rearm/initSettings.sqf @@ -1,7 +1,19 @@ +private _category = [LELSTRING(OptionsMenu,CategoryLogistics), LLSTRING(DisplayName)]; + +[ + QGVAR(enabled), "CHECKBOX", + ELSTRING(common,Enabled), + _category, + true, + true, + {[QGVAR(enabled), _this] call EFUNC(common,cbaSettings_settingChanged)}, + true +] call CBA_fnc_addSetting; + [ QGVAR(level), "LIST", [LSTRING(RearmSettings_level_DisplayName), LSTRING(RearmSettings_level_Description)], - [localize ELSTRING(OptionsMenu,CategoryLogistics), localize LSTRING(DisplayName)], + _category, [[0,1,2],[LSTRING(RearmSettings_vehicle), LSTRING(RearmSettings_magazine), LSTRING(RearmSettings_caliber)],0], // [values, titles, defaultIndex] true, // isGlobal {[QGVAR(level), _this] call EFUNC(common,cbaSettings_settingChanged)} @@ -10,7 +22,7 @@ [ QGVAR(supply), "LIST", [LSTRING(RearmSettings_supply_DisplayName), LSTRING(RearmSettings_supply_Description)], - [localize ELSTRING(OptionsMenu,CategoryLogistics), localize LSTRING(DisplayName)], + _category, [[0,1,2],[LSTRING(RearmSettings_unlimited), LSTRING(RearmSettings_limited), LSTRING(RearmSettings_magazineSupply)],0], // [values, titles, defaultIndex] true, // isGlobal {[QGVAR(supply), _this] call EFUNC(common,cbaSettings_settingChanged)} @@ -18,8 +30,8 @@ [ QGVAR(distance), "SLIDER", - [localize LSTRING(RearmSettings_distance_DisplayName), localize LSTRING(RearmSettings_distance_Description)], - [localize ELSTRING(OptionsMenu,CategoryLogistics), localize LSTRING(DisplayName)], + [LLSTRING(RearmSettings_distance_DisplayName), LLSTRING(RearmSettings_distance_Description)], + _category, [10, 50, 20, 0], true, // isGlobal {[QGVAR(supply), _this] call EFUNC(common,cbaSettings_settingChanged)} diff --git a/optionals/compat_gm/CfgVehicles.hpp b/optionals/compat_gm/CfgVehicles.hpp index a9813fdc0c..3f8d8bf941 100644 --- a/optionals/compat_gm/CfgVehicles.hpp +++ b/optionals/compat_gm/CfgVehicles.hpp @@ -160,7 +160,6 @@ class CfgVehicles { }; class gm_ural4320_reammo_base: gm_ural4320_base { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; diff --git a/optionals/compat_gm/config.cpp b/optionals/compat_gm/config.cpp index 47191aed12..6083886949 100644 --- a/optionals/compat_gm/config.cpp +++ b/optionals/compat_gm/config.cpp @@ -6,7 +6,7 @@ class CfgPatches { units[] = {}; weapons[] = {}; requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"ace_csw", "ace_explosives", "ace_rearm", "ace_refuel", "ace_repair", "gm_core"}; + requiredAddons[] = {"ace_csw", "ace_explosives", "ace_refuel", "ace_repair", "gm_core"}; author = ECSTRING(common,ACETeam); authors[] = {"sancron", "nomisum"}; url = ECSTRING(main,URL); diff --git a/optionals/compat_rhs_afrf3/CfgVehicles.hpp b/optionals/compat_rhs_afrf3/CfgVehicles.hpp index db66255a49..124dc86696 100644 --- a/optionals/compat_rhs_afrf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_afrf3/CfgVehicles.hpp @@ -161,8 +161,7 @@ class CfgVehicles { EGVAR(repair,canRepair) = 1; }; class RHS_Ural_Ammo_Base: RHS_Ural_Base { - transportAmmo = 0; - ace_rearm_defaultSupply = 1200; + EGVAR(rearm,defaultSupply) = 1200; }; class rhs_kraz255b1_base; @@ -183,14 +182,12 @@ class CfgVehicles { }; class rhs_gaz66_ammo_base: rhs_gaz66_vmf { - transportAmmo = 0; - ace_rearm_defaultSupply = 1200; + EGVAR(rearm,defaultSupply) = 1200; }; class rhs_kamaz5350; class rhs_kamaz5350_ammo_base: rhs_kamaz5350 { - transportAmmo = 0; - ace_rearm_defaultSupply = 1200; + EGVAR(rearm,defaultSupply) = 1200; }; class MRAP_02_base_F; diff --git a/optionals/compat_rhs_afrf3/config.cpp b/optionals/compat_rhs_afrf3/config.cpp index ddd2d598fe..3f781a4423 100644 --- a/optionals/compat_rhs_afrf3/config.cpp +++ b/optionals/compat_rhs_afrf3/config.cpp @@ -7,7 +7,7 @@ class CfgPatches { units[] = {}; weapons[] = {QGVAR(2b14_carry), QGVAR(nsv_carry), QGVAR(kord_carry), QGVAR(ags30_carry), QGVAR(spg9_carry), QGVAR(spg9m_carry), QGVAR(metis_carry), QGVAR(kornet_carry)}; requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"ace_explosives", "ace_csw", "ace_rearm", "ace_refuel", "ace_repair", "rhs_main_loadorder"}; + requiredAddons[] = {"ace_explosives", "ace_csw", "ace_refuel", "ace_repair", "rhs_main_loadorder"}; author = ECSTRING(common,ACETeam); authors[] = {"Ruthberg", "GitHawk", "BaerMitUmlaut", "commy2", "Skengman2"}; url = ECSTRING(main,URL); diff --git a/optionals/compat_rhs_usf3/CfgVehicles.hpp b/optionals/compat_rhs_usf3/CfgVehicles.hpp index 87d4c50dee..36d96c8c65 100644 --- a/optionals/compat_rhs_usf3/CfgVehicles.hpp +++ b/optionals/compat_rhs_usf3/CfgVehicles.hpp @@ -198,7 +198,6 @@ class CfgVehicles { }; class rhsusf_M1078A1P2_B_M2_fmtv_usarmy; class rhsusf_M1078A1R_SOV_M2_D_fmtv_socom: rhsusf_M1078A1P2_B_M2_fmtv_usarmy { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 800; transportFuel = 0; EGVAR(refuel,hooks)[] = {{1.1,0.9,-1.2}}; @@ -210,19 +209,16 @@ class CfgVehicles { class rhsusf_HEMTT_A4_base: Truck_01_base_F {}; class rhsusf_M977A4_usarmy_wd: rhsusf_HEMTT_A4_base {}; class rhsusf_M977A4_AMMO_usarmy_wd: rhsusf_M977A4_usarmy_wd { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; class rhsusf_M977A4_BKIT_usarmy_wd: rhsusf_M977A4_usarmy_wd {}; class rhsusf_M977A4_AMMO_BKIT_usarmy_wd: rhsusf_M977A4_BKIT_usarmy_wd { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; class rhsusf_M977A4_BKIT_M2_usarmy_wd: rhsusf_M977A4_usarmy_wd {}; class rhsusf_M977A4_AMMO_BKIT_M2_usarmy_wd: rhsusf_M977A4_BKIT_M2_usarmy_wd { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; @@ -268,7 +264,6 @@ class CfgVehicles { class rhsusf_m113_usarmy: rhsusf_m113tank_base {}; class rhsusf_m113_usarmy_supply: rhsusf_m113_usarmy { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; diff --git a/optionals/compat_rhs_usf3/config.cpp b/optionals/compat_rhs_usf3/config.cpp index 1e169fdf6a..1daab4a14c 100644 --- a/optionals/compat_rhs_usf3/config.cpp +++ b/optionals/compat_rhs_usf3/config.cpp @@ -7,7 +7,7 @@ class CfgPatches { units[] = {}; weapons[] = {QGVAR(m252_carry), QGVAR(m2_carry), QGVAR(mk19_carry), QGVAR(tow_carry)}; requiredVersion = REQUIRED_VERSION; - requiredAddons[] = {"ace_explosives", "ace_javelin", "ace_rearm", "ace_refuel", "ace_repair", "ace_csw", "rhsusf_main_loadorder"}; + requiredAddons[] = {"ace_explosives", "ace_javelin", "ace_refuel", "ace_repair", "ace_csw", "rhsusf_main_loadorder"}; author = ECSTRING(common,ACETeam); authors[] = {"Ruthberg", "GitHawk", "BaerMitUmlaut", "Fyuran"}; url = ECSTRING(main,URL); @@ -23,4 +23,3 @@ class CfgPatches { #include "CfgVehicles.hpp" #include "CfgGlasses.hpp" #include "CfgMagazineGroups.hpp" - diff --git a/optionals/compat_sog/CfgVehicles/wheeled.hpp b/optionals/compat_sog/CfgVehicles/wheeled.hpp index c0561375bd..14ebcaf339 100644 --- a/optionals/compat_sog/CfgVehicles/wheeled.hpp +++ b/optionals/compat_sog/CfgVehicles/wheeled.hpp @@ -16,7 +16,6 @@ class vn_wheeled_m54_repair_base: vn_wheeled_m54_03_base { }; class vn_wheeled_m54_01_base; class vn_wheeled_m54_ammo_base: vn_wheeled_m54_01_base { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; }; @@ -41,7 +40,6 @@ class vn_wheeled_z157_repair_base: vn_wheeled_z157_base { }; class vn_wheeled_z157_01_base; class vn_wheeled_z157_ammo_base: vn_wheeled_z157_01_base { - transportAmmo = 0; EGVAR(rearm,defaultSupply) = 1200; };