Changed SoundManager and Sound classes to respect volume on first play

This commit is contained in:
HackManiac 2013-05-01 21:21:57 +02:00
parent 9f23c378a1
commit 1c4368fcde
2 changed files with 1 additions and 2 deletions

View file

@ -111,7 +111,7 @@ module Phaser {
var tempSound: Sound = new Sound(this._context, this._gainNode, null, volume, loop);
// this is an async process, so we can return the Sound object anyway, it just won't be playing yet
this.decode(key, () => this.play(key), tempSound);
this.decode(key, () => tempSound.play(), tempSound);
return tempSound;
}

View file

@ -54,7 +54,6 @@ module Phaser {
this._buffer = data;
this.isDecoding = false;
this.play();
}