|
@@ -50,23 +50,9 @@ cc.Class({
|
|
|
{
|
|
{
|
|
|
this.TimeLabelScp.InitTime(this.GameStatesScp.totalTime);
|
|
this.TimeLabelScp.InitTime(this.GameStatesScp.totalTime);
|
|
|
},
|
|
},
|
|
|
- //页面退出回调
|
|
|
|
|
- onQuit(data)
|
|
|
|
|
- {
|
|
|
|
|
- console.log('onQuit=',data);
|
|
|
|
|
- },
|
|
|
|
|
- //弹出框回调
|
|
|
|
|
- onQuitModal(res)
|
|
|
|
|
- {
|
|
|
|
|
- if (res.data.confirm) {
|
|
|
|
|
- console.log("退出");
|
|
|
|
|
- }else if(res.data.cancel){
|
|
|
|
|
- console.log("取消退出");
|
|
|
|
|
- }
|
|
|
|
|
- },
|
|
|
|
|
StarGame(target,param)
|
|
StarGame(target,param)
|
|
|
{
|
|
{
|
|
|
- if(this.GameStatesScp.progress != this.GameStatesScp.progressTag.ready) return; //1 ready to start
|
|
|
|
|
|
|
+ if(this.GameStatesScp.progress != this.GameStatesScp.progressTag.default) return;
|
|
|
|
|
|
|
|
this.GameStatesScp.progress = this.GameStatesScp.progressTag.ready; //1 ready to start
|
|
this.GameStatesScp.progress = this.GameStatesScp.progressTag.ready; //1 ready to start
|
|
|
|
|
|
|
@@ -84,11 +70,15 @@ cc.Class({
|
|
|
|
|
|
|
|
this.TimeLabelScp.CountDown(function(){
|
|
this.TimeLabelScp.CountDown(function(){
|
|
|
|
|
|
|
|
- this.GameStatesScp.progress = this.GameStatesScp.progressTag.ready;
|
|
|
|
|
|
|
+ this.GameStatesScp.progress = this.GameStatesScp.progressTag.result;
|
|
|
this.GameStatesScp.PunchTimes = 0;
|
|
this.GameStatesScp.PunchTimes = 0;
|
|
|
this.StartButtonNode.active = true;
|
|
this.StartButtonNode.active = true;
|
|
|
this.TenSecondChallengeBG.active = true;
|
|
this.TenSecondChallengeBG.active = true;
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
|
|
+ this.scheduleOnce(function(){
|
|
|
|
|
+ this.GameStatesScp.progress = this.GameStatesScp.progressTag.default;
|
|
|
|
|
+ }.bind(this),1);
|
|
|
|
|
+
|
|
|
}.bind(this));
|
|
}.bind(this));
|
|
|
}.bind(this));
|
|
}.bind(this));
|
|
|
this.StartButtonNode.active = false;
|
|
this.StartButtonNode.active = false;
|