mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 23:02:03 +00:00
Fix an issue where looping sound effects would play at full volume for a tic after playback began, regardless of distance to the sound
git-svn-id: https://svn.eduke32.com/eduke32@7821 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
e6b700cf9b
commit
2bb93967e1
1 changed files with 1 additions and 6 deletions
|
@ -724,12 +724,7 @@ int S_PlaySound3D(int num, int spriteNum, const vec3_t *pos)
|
|||
return -1;
|
||||
}
|
||||
|
||||
// XXX: why is 'right' 0?
|
||||
// Ambient MUSICANDSFX always start playing using the 3D routines!
|
||||
int const ambsfxp = S_IsAmbientSFX(spriteNum);
|
||||
int const voice = (repeatp && !ambsfxp) ? FX_Play(snd.ptr, snd.siz, 0, -1, pitch, sndist >> 6, sndist >> 6, 0, snd.pr,
|
||||
snd.volume, (sndNum * MAXSOUNDINSTANCES) + sndSlot)
|
||||
: FX_Play3D(snd.ptr, snd.siz, repeatp ? FX_LOOP : FX_ONESHOT, pitch, sndang >> 4, sndist >> 6,
|
||||
int const voice = FX_Play3D(snd.ptr, snd.siz, repeatp ? FX_LOOP : FX_ONESHOT, pitch, sndang >> 4, sndist >> 6,
|
||||
snd.pr, snd.volume, (sndNum * MAXSOUNDINSTANCES) + sndSlot);
|
||||
|
||||
if (voice <= FX_Ok)
|
||||
|
|
Loading…
Reference in a new issue