max1944 16 Posted January 23, 2016 Hello Is it possible to add a primary weapon item to a cfgVehicle unit? I would like to give CTRG Miller a custom weapon: (black MXC rifle with silencer and nightstalker scope). addPrimaryWeaponItem seems not to work and adding a custom loadout for every mission and cutscene is a pain in the ass. I would rather like to patch the cfgVehicle. I would appreciate any help Share this post Link to post Share on other sites
donelsarjo 60 Posted January 23, 2016 https://community.bistudio.com/wiki/ArmA_3_Replacement_Config_Tutorial Share this post Link to post Share on other sites
max1944 16 Posted January 24, 2016 https://community.bistudio.com/wiki/ArmA_3_Replacement_Config_Tutorial I can change the loadout but I don't know how to add a scope and silencer to cfgVehicles units. There is no weapon in this list that would fit. Share this post Link to post Share on other sites
El_Guiguitre 13 Posted January 24, 2016 class CfgWeapons { class arifle_MXC_Black_F; class YourTag_arifle_MXC_Black_F : arifle_MXC_Black_F{ scope = protected; class LinkedItems { class LinkedItemsOptic { slot = "CowsSlot"; item = "opticclassname"; }; class LinkedItemsMuzzle { slot = "MuzzleSlot"; item = "silencerclassname" }; }; }; You just have to replace the classnames (and "YourTag" too...) by the scope and silencer you want to use. Then in CfgVehicles you put the new weapon class you created in weapons[] Hope that helps 1 Share this post Link to post Share on other sites
max1944 16 Posted January 29, 2016 Thank you very much. It worked with this code: class CfgPatches { class cfgWeapons_Mod { units[] = {}; weapons[] = {}; requiredVersion = 0.1; requiredAddons[] = {"A3_Weapons_F"}; }; }; class CfgWeapons { class arifle_MXC_Black_F; class arifle_MXC_Black_NST_pointer_snds_F : arifle_MXC_Black_F { class LinkedItems { class LinkedItemsOptic { slot = "CowsSlot"; item = "optic_Nightstalker"; }; class LinkedItemsMuzzle { slot = "MuzzleSlot"; item = "muzzle_snds_H"; }; class LinkedItemsAcc { slot = "PointerSlot"; item = "acc_pointer_IR"; }; }; }; }; Finally the CTRG guys are equiped properly by default: SOLVED: (There is just one minor thing: Does someone know how to remove/change the goggles/sunglasses on cfgVehicles? (I dislike the yellow sport shades on McKay)) Share this post Link to post Share on other sites
El_Guiguitre 13 Posted January 30, 2016 You're welcome. Glad I could help :) for the classes you can do something like this class CfgPatches { class elg_replacement_glasses { units[] = {}; weapons[] = {}; requiredVersion = 0.1; requiredAddons[] = {"rhsusf", "rhs"}; }; }; class CfgGlasses { class None; class G_Combat : None { identityTypes[] = { "NoGlasses",0,"G_NATO_default",0,"G_NATO_casual",0,"G_NATO_pilot",0,"G_NATO_recon",0,"G_NATO_SF",0,"G_NATO_sniper",0, "G_NATO_diver",0,"G_IRAN_default",0,"G_IRAN_diver",0,"G_GUERIL_default",00,"G_HAF_default",0,"G_CIVIL_female",0,"G_CIVIL_male",0 }; }; And there is an explanation of how facewear works here: https://community.bistudio.com/wiki/Arma_3_Characters_And_Gear_Encoding_Guide#Facewear_configuration 1 Share this post Link to post Share on other sites
max1944 16 Posted January 30, 2016 I noticed the glasses for individual characters are defined in cfgIdentities, but I don't know how to patch it. I don't know the requiredAddons and there are no parents. class CfgPatches { class cfgIdentities_Mod { units[] = {}; weapons[] = {}; requiredVersion = 0.1; requiredAddons[] = {???}; }; }; class cfgIdentities { class EPA_B_McKay { nameSound = "McKay"; face = "WhiteHead_02"; glasses = "G_Combat"; }; }; Share this post Link to post Share on other sites
El_Guiguitre 13 Posted January 30, 2016 For these 5 guys you can also define their glasses in the unit parameters as linkedItems For miller it would be something like this class B_story_SF_Captain_F : B_Soldier_base_F { LinkedItems[] = {"V_PlateCarrierL_CTRG","ItemMap","ItemCompass","ItemWatch","ItemRadio", "G_Aviator"}; respawnLinkedItems[] = {"V_PlateCarrierL_CTRG","ItemMap","ItemCompass","ItemWatch","ItemRadio", "G_Aviator"}; }; }; and you can find the others in the config viewer, classnames are B_CTRG_xxxx_F Share this post Link to post Share on other sites
max1944 16 Posted January 31, 2016 That worked well. Thank you Share this post Link to post Share on other sites