diff --git a/engine/client/snd_al.c b/engine/client/snd_al.c index 5e266d5f4..da9a71d08 100644 --- a/engine/client/snd_al.c +++ b/engine/client/snd_al.c @@ -906,9 +906,7 @@ static void OpenAL_ChannelUpdate(soundcardinfo_t *sc, channel_t *chan, chanupdat { if (schanged == CUR_UPDATE && chan->pos) { //complex update, but not restart. pos contains an offset, rather than an absolute time. - int cursample; - palGetSourcei(src, AL_SAMPLE_OFFSET, &cursample); - palSourcei(src, AL_SAMPLE_OFFSET, cursample + (chan->pos>>PITCHSHIFT)); + palSourcei(src, AL_SAMPLE_OFFSET, (chan->pos>>PITCHSHIFT)); } pitch = (float)chan->rate/(1<pos:0; + int absstartpos = updateonly?sc->GetChannelPos?sc->GetChannelPos(sc, target_chan)<pos:0; extern cvar_t cl_demospeed; chanupdatereason_t chanupdatetype = updateonly?CUR_UPDATE:CUR_EVERYTHING;