Jump to content
Sign in to follow this  
gatordev

RHS weapons using Tier1 sounds (Sound Config Help)

Recommended Posts

I asked this question over in the Tier 1 addon thread but didn't get any traction (although I understand it's a holiday weekend for many).  Looking for help to see what I'm doing wrong here...

 

I'm trying to make a simple sound config to make the RHS M4/M16 weapons inherit Tier 1's suppressed sounds.  Fingolfin has had a look and thinks I'm on the right track, but it's not working in game for me.  I'm absolutely sure it's user error, as I'm exceeding my knowledge pretty quickly.  Here's the config:

 

https://github.com/gatordev/Tier1RHSSounds/blob/main/config.cpp

 

I've re-bin'ed the file to a config.bin and then made a new .pbo with just that config in there.  Arma isn't throwing any errors in the .rpt file and it's showing it loaded, but no sound change.  Anyone point me in the right direction? 

Share this post


Link to post
Share on other sites
31 minutes ago, RCA3 said:

Maybe try add the weapons to the:

// List of weapons (CfgWeapons classes) contained in the addon.

weapons[] = {"rhs_weap_m4_Base", "rhs_weap_m16a4"}; //maybe add all others these inherit from also.

 

https://community.bistudio.com/wiki/CfgPatches

 

It didn't like that.  Arma gave me a startup error saying the weapons have already been called and then it didn't load.  Once I commented that out and recompiled the pbo, Arma loaded fine, but still no change in sounds.

Share this post


Link to post
Share on other sites

I would try something like this below.

Also, you might have caught the copy/paste bug from the forum. Try typing it yourself (just the weapons[] part from my previous post).

 

class cfgpatches {
	class Gator_T1Weap_RHSUSAF {
		projectname = "Gatordev Suppressed RHS sound replacement";
		author = "Gatordev";
		version = "1";
		requiredversion = 0.1;
		requiredaddons[] = {"A3_Data_F_Enoch_Loadorder", "rhsusf_c_weapons", "rhsusf_sounds", "Tier1_Weapons", "Tier1_Weapons2","Tier1_Weapons_cfg"};
   		units[] = {};
		weapons[] = {"rhs_weap_m4_Base", "rhs_weap_m16a4"};
	};
};

class mode_semiauto;	
class mode_burst;	
class mode_fullauto;  

class cfgweapons {
	class arifle_MX_Base_F;

	class rhs_weap_m4_Base : arifle_MX_Base_F {
		class Single : Mode_SemiAuto {
			class BaseSoundModeType {};
			
			class StandardSound : BaseSoundModeType {
				soundSetShot[] = {"RHSUSF_m4_Shot_SoundSet","RHSUSF_rifle_small_Tail_SoundSet","RHSUSF_m4_stereoLayer_SoundSet"};
			};
			
			class silencedsound : basesoundmodetype {
				soundSetShot[] = {"Tier1_416Carbine_silencerShot_SoundSet","Tier1_416Carbine_silencerTail_SoundSet","RHSUSF_sd_M4_stereoLayer_SoundSet"};
			};
		};
		
		class Burst : Mode_Burst {
			class BaseSoundModeType {};
			
			class StandardSound : BaseSoundModeType {
				soundSetShot[] = {"RHSUSF_m4_Shot_SoundSet","RHSUSF_rifle_small_Tail_SoundSet","RHSUSF_m4_stereoLayer_SoundSet"};
			};
			
			class silencedsound : basesoundmodetype {
				soundSetShot[] = {"Tier1_416Carbine_silencerShot_SoundSet","Tier1_416Carbine_silencerTail_SoundSet","RHSUSF_sd_M4_stereoLayer_SoundSet"};
			};
		};
		
		class FullAuto : Mode_FullAuto {
			class BaseSoundModeType {};
			
			class StandardSound : BaseSoundModeType {
				soundSetShot[] = {"RHSUSF_m4_Shot_SoundSet","RHSUSF_rifle_small_Tail_SoundSet","RHSUSF_m4_stereoLayer_SoundSet"};
			};
			
			class silencedsound : basesoundmodetype {
				soundSetShot[] = {"Tier1_416Carbine_silencerShot_SoundSet","Tier1_416Carbine_silencerTail_SoundSet","RHSUSF_sd_M4_stereoLayer_SoundSet"};
			};
		};
	};
	
	class rhs_weap_m16a4 : rhs_weap_m4_Base {
		class Single : Single {
			class BaseSoundModeType {};
			
			class StandardSound : BaseSoundModeType {
				soundSetShot[] = {"RHSUSF_m16_Shot_SoundSet","RHSUSF_rifle_small_Tail_SoundSet","RHSUSF_m16_stereoLayer_SoundSet"};
			};
			
			class silencedsound : basesoundmodetype {
				soundSetShot[] = {"Tier1_416Carbine_silencerShot_SoundSet","Tier1_416Carbine_silencerTail_SoundSet","RHSUSF_sd_M4_stereoLayer_SoundSet"};
			};
		};
		
		class Burst : Burst {
			class BaseSoundModeType {};
			
			class StandardSound : BaseSoundModeType {
				soundSetShot[] = {"RHSUSF_m16_Shot_SoundSet","RHSUSF_rifle_small_Tail_SoundSet","RHSUSF_m16_stereoLayer_SoundSet"};
			};
			
			class silencedsound : basesoundmodetype {
				soundSetShot[] = {"Tier1_416Carbine_silencerShot_SoundSet","Tier1_416Carbine_silencerTail_SoundSet","RHSUSF_sd_M4_stereoLayer_SoundSet"};
			};
		};
	};
};
Edited by RCA3
moved back mode_semiauto, mode_burst, mode_fullauto back to root as per https://community.bistudio.com/wiki/Arma_3_Sound:_ExampleWeaponConfig

Share this post


Link to post
Share on other sites

Did several iterations of what you wrote and some others (including inheriting the arifle_mx_base_F from the base rifle), but no luck.  It's a shame I couldn't get it to work, but I don't have the coding understanding to trouble-shoot it anymore myself.

 

Thanks for trying to help, @RCA3

  • Like 1

Share this post


Link to post
Share on other sites
requiredaddons[] = {"rhsusf_main_loadorder", "Tier1_Weapons", "Tier1_Weapons2","Tier1_Weapons_cfg"};

that should work

  • Like 2
  • Thanks 1

Share this post


Link to post
Share on other sites
2 hours ago, reyhard said:

requiredaddons[] = {"rhsusf_main_loadorder", "Tier1_Weapons", "Tier1_Weapons2","Tier1_Weapons_cfg"};

that should work

 

Thank you, @reyhard.  I noticed RCA3's edits caused some config issues (RHS display name and recoil errors).  Would you recommend me just making the change you have to my original config?

Share this post


Link to post
Share on other sites
On 11/30/2020 at 3:04 PM, reyhard said:

requiredaddons[] = {"rhsusf_main_loadorder", "Tier1_Weapons", "Tier1_Weapons2","Tier1_Weapons_cfg"};

that should work

 

That did it!  Thank you!  Github updated.

  • Like 1

Share this post


Link to post
Share on other sites

Hate to resurrect an old thread, but I wanted to ask if it was possible you could release this on the steam workshop? Or if you don't mind, I could host it there for you. 

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×