mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-22 20:21:26 +00:00
- redirect ST_Sound to a callback because the sound code is game specific
This commit is contained in:
parent
f8e23500c7
commit
72533e2f8a
3 changed files with 8 additions and 1 deletions
|
@ -10,6 +10,7 @@ struct SystemCallbacks
|
|||
bool (*WantNativeMouse)();
|
||||
bool (*CaptureModeInGame)();
|
||||
void (*CrashInfo)(char* buffer, size_t bufflen, const char* lfstr);
|
||||
void (*PlayStartupSound)(const char* name);
|
||||
|
||||
};
|
||||
|
||||
|
|
|
@ -396,7 +396,8 @@ static const int StrifeStartupPicSizes[4 + 2 + 1] =
|
|||
|
||||
static void ST_Sound(const char* sndname)
|
||||
{
|
||||
//S_Sound(CHAN_BODY, 0, sndname, 1, ATTN_NONE);
|
||||
if (sysCallbacks && sysCallbacks->PlayStartupSound)
|
||||
sysCallbacks->PlayStartupSound(sndname);
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
|
|
@ -2639,6 +2639,11 @@ static bool System_CaptureModeInGame()
|
|||
}
|
||||
}
|
||||
|
||||
static void System_PlayStartupSound(const char* sndname)
|
||||
{
|
||||
S_Sound(CHAN_BODY, 0, sndname, 1, ATTN_NONE);
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
// DoomSpecificInfo
|
||||
|
|
Loading…
Reference in a new issue