Custom Sound Problem

Avatar
jwien001
36 Posts
Posted Mar 13, 2010
I'm trying to import a custom sound into my map, but I can't get it to play in the level. It shows up and plays correctly in the sound browser, but when I compile and run the map, it doesn't work. Any ideas?
Advertisement
Registered users don’t see ads! Register now!
Avatar
ASBusinessMagnet
490 Posts
Posted Mar 13, 2010
Replied 1 hour later
Do you have a trigger that activates the sound? :biggrin:
Avatar
jwien001
36 Posts
Posted Mar 13, 2010
Replied 1 hour later
Yes, a button. When the button is pressed, it fires a PlaySound on the ambient_generic. The ambient_generic has Start Silent checked. This setup works with other in-game sounds, so the only difference is the audio file.
Avatar
Mek
459 Posts
Posted Mar 14, 2010
Replied 8 hours later
This must have something to do with the format of the sound. Make sure the WAV file is not compressed (I don't know if other requirements as frequency etc... are required).

Also try looking into the console, it could write an error message saying why it couldn't play the sound.

Avatar
mazk1985
135 Posts
Posted Mar 16, 2010
Replied 2 days later
I had this problem. See if your sound folder in the portal directory is named "sound" and NOT "sounds". took me ages to notice this cos all the other folders have an "s" on the end except sound.

crafty valve imo :smile:

Hope it helps

Advertisement
Registered users don’t see ads! Register now!
Avatar
jwien001
36 Posts
Posted Mar 16, 2010
Replied 23 minutes later
It is "sound". I had read about that problem previously and was careful to avoid it. :razz: That wouldn't be an issue anyways, because as I said, the sound imports and plays correctly in the sound browser, just not in game. The problem is getting the sound to play when I run the map, not importing it into Hammer/Source/Portal.