Bläddra i källkod

Merge branch 'master' of git.mokasz.com:zouyong/team1_nc

wuwangdong 4 år sedan
förälder
incheckning
97cb4e050f
1 ändrade filer med 4 tillägg och 1 borttagningar
  1. 4 1
      assets/script/game/data/module/WarnTipData.ts

+ 4 - 1
assets/script/game/data/module/WarnTipData.ts

@@ -13,7 +13,10 @@ export default class WarnTipData {
 
     setSolution(solution) {
         if (this.curSolution != solution) {
-            this.curSolution = solution;
+            //除了状态0,其他状态只有级别比当前状态高才会赋值,避免异步导致低级状态覆盖高级状态
+            if (solution == 0 || this.curSolution < solution) {
+                this.curSolution = solution;
+            }
             mk.storage.setStorage('solution', this.curSolution);
         }