about summary refs log tree commit diff
path: root/src/game/client/components
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2011-06-27 22:57:06 +0200
committeroy <Tom_Adams@web.de>2011-06-27 22:57:06 +0200
commit47cdd2524b4d5bff7f171686af8260aa8a083c50 (patch)
tree53c8ee7eb8dfcfd98b22ed93dbadf3dd86bc2977 /src/game/client/components
parente8938e3d8044d5f4a71c578c69019052f6a07bf1 (diff)
downloadzcatch-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.cpp2
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];