diff options
| author | oy <Tom_Adams@web.de> | 2011-06-27 22:57:06 +0200 |
|---|---|---|
| committer | oy <Tom_Adams@web.de> | 2011-06-27 22:57:06 +0200 |
| commit | 47cdd2524b4d5bff7f171686af8260aa8a083c50 (patch) | |
| tree | 53c8ee7eb8dfcfd98b22ed93dbadf3dd86bc2977 /src/game/client/components | |
| parent | e8938e3d8044d5f4a71c578c69019052f6a07bf1 (diff) | |
| download | zcatch-47cdd2524b4d5bff7f171686af8260aa8a083c50.tar.gz zcatch-47cdd2524b4d5bff7f171686af8260aa8a083c50.zip | |
do not try to play sound when it isn't enabled
Diffstat (limited to 'src/game/client/components')
| -rw-r--r-- | src/game/client/components/sounds.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/game/client/components/sounds.cpp b/src/game/client/components/sounds.cpp index e9902108..4e9ef5b5 100644 --- a/src/game/client/components/sounds.cpp +++ b/src/game/client/components/sounds.cpp @@ -128,7 +128,7 @@ void CSounds::PlayAndRecord(int Chn, int SetId, float Vol, vec2 Pos) void CSounds::Play(int Chn, int SetId, float Vol, vec2 Pos) { - if(!g_Config.m_SndEnable || (Chn == CHN_MUSIC && !g_Config.m_SndMusic) || m_WaitForSoundJob || SetId < 0 || SetId >= g_pData->m_NumSounds) + if(!g_Config.m_SndEnable || !Sound()->IsSoundEnabled() || (Chn == CHN_MUSIC && !g_Config.m_SndMusic) || m_WaitForSoundJob || SetId < 0 || SetId >= g_pData->m_NumSounds) return; CDataSoundset *pSet = &g_pData->m_aSounds[SetId]; |