We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 70b31c7 commit 6693649Copy full SHA for 6693649
1 file changed
v3/src/sound/BaseSoundManager.js
@@ -37,7 +37,7 @@ var BaseSoundManager = new Class({
37
*/
38
this.volume = 1;
39
/**
40
- * Global playback rate at which all the audio assets will be played.
+ * Global playback rate at which all the sounds will be played.
41
* Value of 1.0 plays the audio at full speed, 0.5 plays the audio at half speed
42
* and 2.0 doubles the audio's playback speed.
43
*
@@ -113,7 +113,11 @@ var BaseSoundManager = new Class({
113
}
114
return sound;
115
},
116
- play: NOOP,
+ play: function (key, config) {
117
+ var sound = this.add(key);
118
+ sound.events.once('SOUND_ENDED', sound.destroy.bind(sound));
119
+ sound.play(config);
120
+ },
121
playAudioSprite: NOOP,
122
remove: NOOP,
123
removeByKey: NOOP,
0 commit comments