- Fix loads of format string bugs

- Fix locally looping sounds, thanks to Timbo
This commit is contained in:
Thilo Schulz committed 2007-01-24 21:23:21 +00:00
1 parent 4b9df8d9e9
commit 5dc3b35b49
9 files changed
+28 -30

No files matched your search

+4 -6
View File
@@ -530,15 +530,13 @@ Adapt the gain if necessary to get a quicker fadeout when the source is too far
static void S_AL_ScaleGain(src_t *chksrc, vec3_t origin)
{
float distance;
if(chksrc->local)
distance = VectorLength(origin);
else
if(!chksrc->local)
distance = Distance(origin, lastListenerOrigin);
// If we exceed a certain distance, scale the gain linearly until the sound
// vanishes into nothingness.
if((distance -= s_alMaxDistance->value) > 0)
if(!chksrc->local && (distance -= s_alMaxDistance->value) > 0)
{
float scaleFactor;