From 89b6d5e9a9c90426a7defdd8947e83cfd0ae2550 Mon Sep 17 00:00:00 2001 From: molivier Date: Thu, 25 Nov 2004 09:04:37 +0000 Subject: [PATCH] Fixed ambient sound volume (it was reset each frame, and cannot change by more than the value of the "ambient_fade" cvar each frame... you do the math). Thanks to Tomaz and Urre for the bug report git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4785 d7cf8633-e32d-0410-b094-e92efae38249 --- snd_main.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/snd_main.c b/snd_main.c index af6275c6..a7b8d022 100644 --- a/snd_main.c +++ b/snd_main.c @@ -320,6 +320,7 @@ void S_ServerSounds (char serversound [][MAX_QPATH], unsigned int numsounds) channels[i].sfx = ambient_sfxs[i]; channels[i].flags |= CHANNELFLAG_FORCELOOP; + channels[i].master_vol = 0; } } @@ -762,10 +763,6 @@ void S_UpdateAmbientSounds (void) channel_t *chan; qbyte ambientlevels[NUM_AMBIENTS]; - // Mute ambient sounds until proven otherwise - for (ambient_channel = 0 ; ambient_channel < NUM_AMBIENTS;ambient_channel++) - channels[ambient_channel].master_vol = 0; - if (ambient_level.value <= 0 || !cl.worldmodel || !cl.worldmodel->brush.AmbientSoundLevelsForPoint) return; -- 2.39.2