Adding Player.BulletDamage sound entry in game_sounds_player.txt?

Moved my initial post to this topic since I figured it’s more appropriate here.


Unfortunately game_sounds_player.txt doesn’t have a sound entry for when the player gets hit by bullets or getting bitch slapped with a gun, wanted to add the player hurt sounds whenever you get hit in the campaign. Half Life 2 didn’t have this either though so I’m not sure how this could be done. Haven’t dealt with the Hammer editor before, only tweaks I’ve ever done were editing the script files, amongst other things.

I’ve found this post from a blog that seems to have what I’m looking for but have no idea where the player.cpp file is.

player.cpp is a source file, which is compiled into the engine executable before building and cannot be reextracted once the game has shipped. You can add custom sounds on a map-by-map basis as per this post, but currently the game does not support doing so globally. The developers have occasionally mentioned that this is functionality they would like to add, but that the SteamPipe system used by Valve has made it very difficult.

Damn, I’m guessing the devs haven’t released the source code/files for global stuff like player attributes?

Adding sounds on a per-map basis, would that still work for player hurt sounds such as when getting shot? I figure the player would fall under the ‘global’ category and thus that sort of thing wouldn’t work if trying to add it to the map.

Founded in 2004, Leakfree.org became one of the first online communities dedicated to Valve’s Source engine development. It is more famously known for the formation of Black Mesa: Source under the 'Leakfree Modification Team' handle in September 2004.