Properly setting currentTime variable value when detecting missed looping in update method

This commit is contained in:
Pavle Goloskokovic 2018-01-14 15:24:55 +01:00
parent 5b0cf55bfc
commit 65538e3408

View file

@ -199,8 +199,8 @@ var HTML5AudioSound = new Class({
}
}
else if (currentTime < startTime) {
currentTime =
this.audio.currentTime += startTime;
this.audio.currentTime += startTime;
currentTime = this.audio.currentTime;
}
if (currentTime < this.previousTime) {
this.events.dispatch(new SoundEvent(this, 'SOUND_LOOP'));