Selaa lähdekoodia

Audio: Fix pause

Mugen87 7 vuotta sitten
vanhempi
commit
6d635efe76
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      src/audio/Audio.js

+ 1 - 1
src/audio/Audio.js

@@ -108,7 +108,7 @@ Audio.prototype = Object.assign( Object.create( Object3D.prototype ), {
 		if ( this.isPlaying === true ) {
 
 			this.source.stop();
-			this.offset += this.context.currentTime - this.startTime;
+			this.offset += ( this.context.currentTime - this.startTime ) * this.playbackRate;
 			this.isPlaying = false;
 
 		}