SV_Startsound: file.wav not precached (0)

A Forum Thread for Left 4 Dead 2

SEX! Ok, we got your attention. We are one of the oldest mod sites on the Interwebs. Sign up and maximize your browsing experience.

  • Subscribe: Get notified of new submissions like this.
  • Say Thanks: Show your appreciation by sending RndwaveIsMyFriend points.
  • Post: Give RndwaveIsMyFriend your thoughts on this Thread.
  • Vote: Help RndwaveIsMyFriend win the Monthly Awards.
  • Flag: Alert moderators and warn members of a problem with this Thread.
  • Watch: Get notified when this Thread is updated.
Mascot

Resistance is futile...

Sign up

Already a Bananite? Login

Updates

Solution found!
  • Hahaha, fuck you, game!
Turns out if you use the files that the game won't precache in an event that doesn't happen in that level, the game will suddenly realize it's supposed to use these files and will precache them! Yay!

Example, in c2m1_highway_level_sounds:

//An event that isn't used in this level, but the game still sees it, and will precache the files this event uses.
//This means I can force it to precache files that, for some *REALLY* *FUCKING* *STUPID* reason, it won't otherwise.
"c2m2.carousel_music"

{
"channel" "CHAN_STATIC"
"volume" "1.0"
"soundlevel" "SNDLVL_NONE"

"rndwave"

{
"wave" "WitchSongs/SongOfRuin.wav"
"wave" "WitchSongs/Nick/RuinBomb1.wav"
}

}

And later in the script:

//GRENADE!
"Gambler_Grenade01"

{
"channel" "CHAN_STATIC"
"soundlevel" "SNDLVL_NONE"

"rndwave"

{
"wave" "WitchSongs/SongOfRuin.wav"
"wave" "WitchSongs/Nick/RuinBomb1.wav"
}

}
10mo
Different Approach
  • Asking a different question
11mo
This message keeps popping up in the console every time the custom sound for the fireworks boxes fails to play. This doesn't appear with any of my other custom sounds, it doesn't matter what the file is called, and it doesn't matter if it's an mp3 or wav. Does anyone know how to precache sound files so I can fix this?

Posts

  • 1y
    Doktor haus avatar
    Doktor haus username pic Joined 7y ago
    Offline
    Destiny Flag Affiliation: Destiny
    14,201 points Ranked 312th
    25 medals 1 legendary 4 rare
    • Reached 100 subscribers Medal icon
    • 3rd Place - Original Weapons Skinning Contest Medal icon
    • Reached 50 subscribers Medal icon
    • Received thanks 50 times Medal icon
    • 6 years a member Medal icon
    • Tutor of the Month, April 2012 Medal icon
    Doktor haus avatar
    Doktor haus
    Destiny Flag
    Affiliation
    Destiny
    Enter this console command in game:

    snd_buildsoundcachefordirectory/addons/myfolder

    Replace "myfolder" with the name of your custom addon folder . That generates a sound.cache file in the folder, which should then be packed into a VPK.

    L4D2 modder avatar
    Mantra
    L4D2 modder
  • 11mo
    RndwaveIsMyFriend avatar
    RndwaveIsMyFriend Joined 2y ago
    Offline
    449 points Ranked 9928th
    I think I managed to work around it the first time by renaming the file to the one I was replacing and copying the directory path, but that won't work this time.

    There are a handful of audio files that have a chance of playing when Nick says one of his pipe bomb lines. Using the old method would only allow one replacement file per line, which I suspect will grow old fast.

    Currently, I'm only testing 2 per line, one with the voice line included (RuinBombVoice) and one that's just the song (RuinBomb). Interestingly enough, the game will always try to play RuinBombVoice and then give the "sound not precached" error in the console. Forcing it to play RuinBomb instead doesn't show an error in the console, but it is likewise nonfunctional.

    I tried moving the mod folder to addons and using the suggested console command, but got the same results. Does anyone know why this message shows up and how to beat it?
    ALL the sound files!
  • 11mo
    Cyber Moonlight avatar
    Cyber Moonlight username pic Joined 2y ago
    Wandering
    1,454 points Ranked 3342nd
    12 medals 4 rare
    • GameBanana’s Christmas Giveaway 2016 Day Eighteen Winner! Medal icon
    • 8-14 Entries! GameBanana’s Christmas Giveaway 2016 Medal icon
    • Returned 1000 times Medal icon
    • 8-14 Entries! GameBanana’s Christmas Giveaway 2017 Medal icon
    • One month a member Medal icon
    • 2016 Survey Participant Medal icon
    Posted by RndwaveIsMyFriend

    I think I managed to work around it the first time by renaming the file to the one I was replacing and copying the directory path, but that won't work this time.

    There are a handful of audio files that have a chance of playing when Nick says one of his pipe bomb lines. Using the old method would only allow one replacement file per line, which I suspect will grow old fast.

    Currently, I'm only testing 2 per line, one with the voice line included (RuinBombVoice) and one that's just the song (RuinBomb). Interestingly enough, the game will always try to play RuinBombVoice and then give the "sound not precached" error in the console. Forcing it to play RuinBomb instead doesn't show an error in the console, but it is likewise nonfunctional.

    I tried moving the mod folder to addons and using the suggested console command, but got the same results. Does anyone know why this message shows up and how to beat it?

    You haven't rebuilt your overall sound cache. Enter the game open the console type snd_rebuildaudiocache and wait for it to finish. Note that you cannot do anything while this is working.
    Power core: Online! avatar
    Mantra
    Power core: Online!
  • 11mo
    RndwaveIsMyFriend avatar
    RndwaveIsMyFriend Joined 2y ago
    Offline
    449 points Ranked 9928th
    Posted by Evil King Sombra

    You haven't rebuilt your overall sound cache. Enter the game open the console type snd_rebuildaudiocache and wait for it to finish. Note that you cannot do anything while this is working.
    Unfortunately, that didn't work, either. You think maybe it's something that you just can't modify with sound scripts?
    ALL the sound files!
  • 11mo
    RndwaveIsMyFriend avatar
    RndwaveIsMyFriend Joined 2y ago
    Offline
    449 points Ranked 9928th
    So, it seems like this could be fixed by precaching the audio files. Problem is, I don't know how to do that, and apparently neither does Google, as my searches have produced no useful results.

    Does anyone happen to know how to precache audio files for a mod of an official campaign, step-by-step?
    ALL the sound files!

Embed

Share banner
Image URL:
HTML embed code:
BB embed code:
Markdown embed code:

Submitter

Sign up to access this!
Sign up to access this!
Sign up to access this!
Sign up to access this!

Category

Stats

Posts
5
Views
1,984
Date Added
1y
Date Updated
10mo
bcp.crwdcntrl.net tracking pixel