Page 1 of 1

Can't Load Custom Audio File - Source Mod

PostPosted: Tue Jun 15, 2010 7:49 am
by bajamanz
Hey guys, I've been having a lot of trouble getting a custom audio file to play for a source mod I'm working on. Everytime I try to trigger the audio file by shooting it gives me the error: "can't find sound file, sound file does not exist"

My sound directory is modname/sounds/weapons/firemage for the sound I'm trying to play. The sound file is a 44.1khz/16bit clip called firebolt01.wav

In game_sounds_weapons I have:

"Weapon_Firebolt.Cast"
{
"channel" "CHAN_WEAPON"
"volume" "1"
"soundlevel" "SNDLVL_GUNFIRE"
"pitch" "80, 120"
"wave" "weapons/firemage/firebolt01.wav"
}

and in the actual weapon script file I have:

SoundData
{
"single_shot" "Weapon_Firebolt.Cast"
}

Is there something I"m missing that's making it not find the sound file? The references to the sound file match, is it something with embedding with PakRat (i though that's only for maps)?

Thanks!

-Baja

Re: Can't Load Custom Audio File - Source Mod

PostPosted: Tue Jun 15, 2010 7:57 am
by Dives
Have you tried rebuilding the audio cache? Type snd_rebuildaudiocache into console. Then reload the map and see if it works.

Re: Can't Load Custom Audio File - Source Mod

PostPosted: Tue Jun 15, 2010 8:05 am
by bajamanz
Dives wrote:Have you tried rebuilding the audio cache? Load up the map and type snd_rebuildaudiocache into console. Then reload the map and see if it works.


It's a source mod so it doesn't update anything when I type that. It's not finding the file for some reason, yet I'm following the correct source directory path I think...

Re: Can't Load Custom Audio File - Source Mod

PostPosted: Tue Jun 15, 2010 3:34 pm
by Jordash
try changing the Weapon_Firebolt.Cast to a default HL2 sound file in game_sounds_weapons, then you can find out if it is the wav or the script