Commit 6a222b89 authored by Lwd's avatar Lwd

aaaa

parent dafbde31
......@@ -216,14 +216,11 @@ var game = cc.Class({
},
//播放标题音效
playAudioTitle: function (cb) {
playAudioTitle: function () {
//获得播放路径
var path = g.data_mgr.data.contentObj.audio_url;
if (path == undefined) {
cb && cb();
}
g.res_mgr.playAudioByUrl(path, (url) => {
g.snd_mgr.playEffect(url, cb);
g.snd_mgr.playEffect(url);
});
},
......
......@@ -64,7 +64,7 @@ var speaker = cc.Class({
g.snd_mgr.playEffect(this.eff_showPop);
},
//游戏开始
play_start: function (cb) {
g.snd_mgr.playEffect(this.eff_start, cb);
play_start: function () {
g.snd_mgr.playEffect(this.eff_start);
},
});
......@@ -116,12 +116,15 @@ g.data_mgr = {
g.game.inst.UpdataUi();
//播放游戏开始音效
g.speaker.inst.play_start(() => {
g.game.inst.playAudioTitle(() => {
g.game.inst.mask_node.active = false;
//游戏开始
g.game.inst.gameStart();
});
});
g.speaker.inst.play_start();
setTimeout(() => {
g.game.inst.playAudioTitle();
}, 2000);
setTimeout(() => {
g.game.inst.mask_node.active = false;
//游戏开始
g.game.inst.gameStart();
}, 4000)
},
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment