From 24d3c6b2a2b28350a840d3cd54a018d36c4c730d Mon Sep 17 00:00:00 2001 From: Tim Angus Date: Thu, 29 Sep 2005 22:35:05 +0000 Subject: [PATCH] * Fixed the bug where the "doppler" effect code could cause a temporary client lock up --- code/client/snd_dma.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/code/client/snd_dma.c b/code/client/snd_dma.c index 758f9883..2a99aae2 100644 --- a/code/client/snd_dma.c +++ b/code/client/snd_dma.c @@ -781,6 +781,9 @@ void S_AddLoopingSound( int entityNum, const vec3_t origin, const vec3_t velocit if (loopSounds[entityNum].dopplerScale<=1.0) { loopSounds[entityNum].doppler = qfalse; // don't bother doing the math } + else if (loopSounds[entityNum].dopplerScale>(float)SND_CHUNK_SIZE) { + loopSounds[entityNum].dopplerScale = (float)SND_CHUNK_SIZE; + } } loopSounds[entityNum].framenum = cls.framecount;