Loading sound scripts

So a few months ago, there was a big update that made Gmod un-playable for a few days (Patch 119). Anyway, Garry took out the system that loaded custom sound scripts, so now all sounds that aren’t included in Garry’s presets will not play in game. You can still play the WAV files but those lag more, overlap, and cancel each other out. This means that any mods or addons that use custom sounds are essentially broken, which is a big problem for me because I manage 2 relatively large mods (GDC and GDCW) and they each have a lot of custom sounds that require scripting. I’ve gotten hundreds of requests from people who don’t understand that this isn’t my fault to fix the sounds, and since I can’t do it, I’m asking Garry to either revert to the previous way of loading all sound scripts at startup or to add something that allows people to choose which sound scripts they want loaded.

Garrys Mod has always been a game that’s upheld by 3rd party mods such as my own, and I think this major problem should be fixed right away. It’s been a few months since this happened and I’m tired of hearing “It will be fixed soon.” I know you may not be motivated to fix this because I already paid my 10$ for Gmod back in early 2007, but I’ve been a productive part of the Gmod community and I think you need to look into this problem. Thanks in advance!

-Sound scripts broken in Patch 119.
-Nothing I can do to fix it
-Scripts can be added manually to work in single player, but will still not work in Multiplayer.

Right now adding sound scripts has to be done manually and is unfortunately too difficult of most Gmod players.

  1. Go to garrysmod\garrysmod\scripts\sounds and place the script file in it.
  2. Go to garrysmod\garrysmod\scripts\game_sounds_manifest and add a line like “precache_file” “scripts/sounds/level_sounds_citadel.txt” with the name of your script.
  3. Start Gmod.

It sounds simple but telling dozens of people to do this each day gets old really fast. Here is a list of scripts that get loaded by default:


	"precache_file"		"scripts/sounds/cs_game_sounds_radio.txt"
	"precache_file"		"scripts/sounds/cs_game_sounds_weapons.txt"
	"precache_file"		"scripts/sounds/dod_game_sounds_weapons.txt"
	"precache_file"		"scripts/sounds/game_sounds_vehicles_ep2.txt"
	"precache_file"		"scripts/sounds/game_sounds_weapons_ep2.txt"
	"precache_file"		"scripts/sounds/hl1_game_sounds.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_ambient_generic.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_header.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_items.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_manifest.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_physics.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_player.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_ui.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_vehicles.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_weapons.txt"
	"precache_file"		"scripts/sounds/hl2_game_sounds_world.txt"
	"precache_file"		"scripts/sounds/l4d_game_sounds_weapons.txt"
	"precache_file"		"scripts/sounds/level_sounds_breencast.txt"
	"precache_file"		"scripts/sounds/level_sounds_canals.txt"
	"precache_file"		"scripts/sounds/level_sounds_canals2.txt"
	"precache_file"		"scripts/sounds/level_sounds_citadel.txt"
	"precache_file"		"scripts/sounds/level_sounds_coast.txt"
	"precache_file"		"scripts/sounds/level_sounds_eli_lab.txt"
	"precache_file"		"scripts/sounds/level_sounds_k_lab.txt"
	"precache_file"		"scripts/sounds/level_sounds_k_lab2.txt"
	"precache_file"		"scripts/sounds/level_sounds_music.txt"
	"precache_file"		"scripts/sounds/level_sounds_novaprospekt.txt"
	"precache_file"		"scripts/sounds/level_sounds_ravenholm.txt"
	"precache_file"		"scripts/sounds/level_sounds_ravenholm2.txt"
	"precache_file"		"scripts/sounds/level_sounds_streetwar.txt"
	"precache_file"		"scripts/sounds/level_sounds_streetwar2.txt"
	"precache_file"		"scripts/sounds/level_sounds_trainyard.txt"
	"precache_file"		"scripts/sounds/npc_sounds_alyx.txt"
	"precache_file"		"scripts/sounds/npc_sounds_alyx_episodic.txt"
	"precache_file"		"scripts/sounds/npc_sounds_antlion.txt"
	"precache_file"		"scripts/sounds/npc_sounds_antlion_episodic.txt"
	"precache_file"		"scripts/sounds/npc_sounds_antlion_grub_episodic.txt"
	"precache_file"		"scripts/sounds/npc_sounds_antlionguard.txt"
	"precache_file"		"scripts/sounds/npc_sounds_attackheli.txt"
	"precache_file"		"scripts/sounds/npc_sounds_barnacle.txt"
	"precache_file"		"scripts/sounds/npc_sounds_barney.txt"
	"precache_file"		"scripts/sounds/npc_sounds_birds.txt"
	"precache_file"		"scripts/sounds/npc_sounds_blackheadcrab.txt"
	"precache_file"		"scripts/sounds/npc_sounds_citizen.txt"
	"precache_file"		"scripts/sounds/npc_sounds_combine_ball.txt"
	"precache_file"		"scripts/sounds/npc_sounds_combine_mine.txt"
	"precache_file"		"scripts/sounds/npc_sounds_combinecamera.txt"
	"precache_file"		"scripts/sounds/npc_sounds_dog.txt"
	"precache_file"		"scripts/sounds/npc_sounds_dropship.txt"
	"precache_file"		"scripts/sounds/npc_sounds_eli.txt"
	"precache_file"		"scripts/sounds/npc_sounds_env_headcrabcanister.txt"
	"precache_file"		"scripts/sounds/npc_sounds_fastheadcrab.txt"
	"precache_file"		"scripts/sounds/npc_sounds_fastzombie.txt"
	"precache_file"		"scripts/sounds/npc_sounds_fastzombie_episodic2.txt"
	"precache_file"		"scripts/sounds/npc_sounds_gman.txt"
	"precache_file"		"scripts/sounds/npc_sounds_gunship.txt"
	"precache_file"		"scripts/sounds/npc_sounds_headcrab.txt"
	"precache_file"		"scripts/sounds/npc_sounds_hunter.txt"
	"precache_file"		"scripts/sounds/npc_sounds_ichthyosaur.txt"
	"precache_file"		"scripts/sounds/npc_sounds_manhack.txt"
	"precache_file"		"scripts/sounds/npc_sounds_metropolice.txt"
	"precache_file"		"scripts/sounds/npc_sounds_ministrider_episodic.txt"
	"precache_file"		"scripts/sounds/npc_sounds_poisonzombie.txt"
	"precache_file"		"scripts/sounds/npc_sounds_rollermine.txt"
	"precache_file"		"scripts/sounds/npc_sounds_scanner.txt"
	"precache_file"		"scripts/sounds/npc_sounds_sniper.txt"
	"precache_file"		"scripts/sounds/npc_sounds_soldier.txt"
	"precache_file"		"scripts/sounds/npc_sounds_stalker.txt"
	"precache_file"		"scripts/sounds/npc_sounds_strider.txt"
	"precache_file"		"scripts/sounds/npc_sounds_strider_episodic2.txt"
	"precache_file"		"scripts/sounds/npc_sounds_turret.txt"
	"precache_file"		"scripts/sounds/npc_sounds_turret_episodic2.txt"
	"precache_file"		"scripts/sounds/npc_sounds_vortigaunt.txt"
	"precache_file"		"scripts/sounds/npc_sounds_zombie.txt"
	"precache_file"		"scripts/sounds/phx.txt"
	"precache_file"		"scripts/sounds/tf2_game_sounds_weapons.txt"
	"precache_file"		"scripts/sounds/snds_insurgency_1.txt"


As for telling people to add stuff to a Script file, you could make(Or I could, or most people could) a small program that edits it in for them, and just tell them to download and run that.

I would really hope this would be updated in future updates of Garry’s Mod, since currently all the edited soundscript files cannot be uploaded and are ‘whitelisted’. At first, I thought this was a bug on my side until I saw that you can only add edited soundscript files manually within Garry’s Mod.

I haven’t tried out the sound.Add for sound scripts, although I’m not sure if you can override all the sounds. When uploading an addon to the workshop it blocks it from uploading since theres a soundscript involved within the content folder. So if I were to override a certain sound for example concrete footsteps it would look something like this:

// My goal is to add more than 4 soundfiles, so it would be concrete1-8 instead of concrete1-4 which is the default for gmod and other source games (other than Portal 2).
	"soundlevel"		"SNDLVL_75dB"
	"volume"		"1.0"
	"pitch"			"PITCH_NORM"
		"wave"		"player/footsteps/concrete1.wav"
		"wave"		"player/footsteps/concrete2.wav"
		"wave"		"player/footsteps/concrete3.wav"
		"wave"		"player/footsteps/concrete4.wav"

	"soundlevel"		"SNDLVL_75dB"
	"volume"		"1.0"
	"pitch"			"PITCH_NORM"
		"wave"		"player/footsteps/concrete5.wav"
		"wave"		"player/footsteps/concrete6.wav"
		"wave"		"player/footsteps/concrete7.wav"
		"wave"		"player/footsteps/concrete8.wav"