Hosting and domain costs until October 2024 have been generously sponsored by dumptruck_ds. Thank you!

precache sound

From Quake Wiki

string precache_sound(string soundPath)

Usage[edit]

Precaches a sound so it can be played during the map. Precaching must be done at map load. Sounds cannot be played if they haven't been precached.

Parameters[edit]

  • soundPath
The path of the sound file. Supports WAV (.wav) files.

Return[edit]

The passed sound file path. Does nothing.

Example[edit]

// Precache a sound in the monster's initialization function for use later
void monster_my_monster()
{
    precache_sound("mymonster/missile.wav");

    // ...
}