MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / FindSoundName

Function FindSoundName

sndlib/soundload.cpp:559–569  ·  view source on GitHub ↗

Searches thru all sounds for a specific name, returns -1 if not found or index of sound with name

Source from the content-addressed store, hash-verified

557// Searches thru all sounds for a specific name, returns -1 if not found
558// or index of sound with name
559int FindSoundName(const char *name) {
560 int i;
561
562 ASSERT(name != NULL);
563
564 for (i = 0; i < MAX_SOUNDS; i++)
565 if (Sounds[i].used && !stricmp(name, Sounds[i].name))
566 return i;
567
568 return -1;
569}
570
571// Given a filename, loads the sound.
572int LoadSound(char *filename) {

Callers 15

mng_LoadNetSoundPageFunction · 0.85
mng_LoadLocalSoundPageFunction · 0.85
mng_RenamePageFunction · 0.85
mng_PopAddonPagesFunction · 0.85
RemapSoundsFunction · 0.85
OnAddSoundMethod · 0.85
SaveSoundsOnCloseMethod · 0.85
InputSoundNameFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected