1
0
Эх сурвалжийг харах

修复60级通关后卡死的BUG

dzduole 1 сар өмнө
parent
commit
a78addc268

+ 34 - 2
client/laya/bin/js/bundle.js

@@ -4666,6 +4666,7 @@
                 }));
             }
             else {
+                console.log('zh:startGame no power');
                 xGame.uiMgr.Show(UIPower);
             }
         }
@@ -6672,17 +6673,31 @@
         clickRightBtn() {
             switch (xGame.common.gameMode) {
                 case GameMode.classic:
+                    console.log('zh:clickRightBtn 111');
                 case GameMode.bigMove:
+                    console.log('zh:clickRightBtn 222');
                     this.restartGame();
                     break;
                 case GameMode.placeBall:
+                    console.log('zh:clickRightBtn 333');
                     let level = xGame.common.placeBallCurLevel;
                     let data = DataMgr.getPlaceBallLevel(level);
                     let curPss = data.play && !data.isCur;
                     if (curPss) {
-                        this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                        console.log('zh:clickRightBtn 333-111');
+                        console.log('zh:当前LV=' + level);
+                        if (level == 60) {
+                            xGame.uiMgr.Show(UIMsg, "Congratulations on passing all levels.");
+                            Laya.timer.once(3000, this, () => {
+                                this.returnHome();
+                            });
+                        }
+                        else {
+                            this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                        }
                     }
                     else {
+                        console.log('zh:clickRightBtn 333-000');
                         Moyu.sendDataEvent("placeBallNextLevel");
                         Moyu.showVideoAd(() => {
                             DataMgr.setPlaceBallLevel(level, 1);
@@ -6691,6 +6706,7 @@
                     }
                     break;
                 default:
+                    console.log('zh:clickRightBtn 444');
                     break;
             }
         }
@@ -18581,17 +18597,31 @@
         clickRightBtn() {
             switch (xGame.common.gameMode) {
                 case GameMode.classic:
+                    console.log('zh:clickRightBtn 111');
                 case GameMode.bigMove:
+                    console.log('zh:clickRightBtn 222');
                     this.restartGame();
                     break;
                 case GameMode.placeBall:
+                    console.log('zh:clickRightBtn 333');
                     let level = xGame.common.placeBallCurLevel;
                     let data = DataMgr.getPlaceBallLevel(level);
                     let curPss = data.play && !data.isCur;
                     if (curPss) {
-                        this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                        console.log('zh:clickRightBtn 333-111');
+                        console.log('zh:当前LV=' + level);
+                        if (level == 60) {
+                            xGame.uiMgr.Show(UIMsg$1, "Congratulations on passing all levels.");
+                            Laya.timer.once(3000, this, () => {
+                                this.returnHome();
+                            });
+                        }
+                        else {
+                            this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                        }
                     }
                     else {
+                        console.log('zh:clickRightBtn 333-000');
                         Moyu.sendDataEvent("placeBallNextLevel");
                         Moyu.showVideoAd(() => {
                             DataMgr.setPlaceBallLevel(level, 1);
@@ -18600,6 +18630,7 @@
                     }
                     break;
                 default:
+                    console.log('zh:clickRightBtn 444');
                     break;
             }
         }
@@ -18737,6 +18768,7 @@
                 }));
             }
             else {
+                console.log('zh:startGame no power');
                 xGame.uiMgr.Show(UIPower$1);
             }
         }

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
client/laya/bin/js/bundle.js.map


+ 18 - 1
client/laya/src/ui/UIGameEnd.ts

@@ -12,6 +12,7 @@ import { UIGame } from "./UIGame";
 import UIInvitation from "./UIInvitation";
 import UIMain from "./UIMain";
 import UIPower from "./UIPower";
+import UIMsg from "./UIMsg";
 export default class UIGameEnd extends UIBase {
     public ui: ui_UIGameEnd;
     public success: boolean = false;
@@ -387,19 +388,34 @@ export default class UIGameEnd extends UIBase {
     clickRightBtn() {
         switch (xGame.common.gameMode) {
             case GameMode.classic:
+                console.log('zh:clickRightBtn 111');
             case GameMode.bigMove:
+                 console.log('zh:clickRightBtn 222');
                 this.restartGame();
                 break;
             case GameMode.placeBall:
+                 console.log('zh:clickRightBtn 333');
                 //直接进入下一关,若当前关卡没有通关则当前关卡按照1星通关
                 let level = xGame.common.placeBallCurLevel;
                 let data = DataMgr.getPlaceBallLevel(level);
                 //当前关卡是否通关
                 let curPss = data.play && !data.isCur;
                 if (curPss) {
-                    this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                    console.log('zh:clickRightBtn 333-111');
+                    console.log('zh:当前LV='+level)
+                    if (level == 60) {
+                       xGame.uiMgr.Show(UIMsg, "Congratulations on passing all levels.")
+                      // this.ui.rightBtn.visible = false;
+                      Laya.timer.once(3000, this, () => {
+                           this.returnHome();
+                      });
+                     
+                    }else{
+                        this.powerStartPlaceBallLevel(level + 1, this.ui.rightBtn);
+                    }   
                 }
                 else {
+                    console.log('zh:clickRightBtn 333-000');
                     //当前关卡未通关
                     Moyu.sendDataEvent("placeBallNextLevel");
                     Moyu.showVideoAd(() => {
@@ -412,6 +428,7 @@ export default class UIGameEnd extends UIBase {
                 }
                 break;
             default:
+                 console.log('zh:clickRightBtn 444');
                 break;
         }
     }

+ 1 - 0
client/laya/src/ui/UILevelProp.ts

@@ -133,6 +133,7 @@ export default class UILevelProp extends UIBase {
             //
         }
         else {
+            console.log('zh:startGame no power')
             xGame.uiMgr.Show(UIPower);
         }
     }

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно