Skip to content

Commit

Permalink
fix audioEngine deprecated code for fireball/issues/6058
Browse files Browse the repository at this point in the history
  • Loading branch information
knoxHuang committed Jul 18, 2017
1 parent 8c24ea1 commit 91c5e75
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cocos2d/audio/deprecated.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ exports.deprecated = function (audioEngine) {
// cc.warn(INFO, 'audioEngine.playEffect', 'audioEngine.play');

return function (url, loop, volume) {
return audioEngine.play(url, loop, volume === undefined ? effectsVolume : volume);
return audioEngine.play(url, loop || false, volume || effectsVolume);
}
});
js.get(audioEngine, 'setEffectsVolume', function (volume) {
Expand Down

0 comments on commit 91c5e75

Please sign in to comment.