Browse Source

1.FIX兔子结果返回太快 导致spin点击动画还没有播放完就重置的问题
2.金币不足的处理

lhj 4 months ago
parent
commit
90fd819286

+ 2 - 1
luckypot_sp/assets/SubGame/slotForestbundle/script/ForestGameFrameView.ts

@@ -907,7 +907,8 @@ export default class ForestGameFrameView extends cc.Component {
     showBalanceLessTip() {
         AudioPlayer.playEffect("sound/moneyless", false);//下注时金钱不足
         // ui.Toast.show(i18nMgr._getLabel("chip_no_enough", []), false);
-        cc.director.emit("showNoMoneyTip");
+        // cc.director.emit("showNoMoneyTip");
+        this.frame.showLowLackMoney()
         this.touchFlag = false;
         this.spinBtnControl.showEnable1()
     }

+ 2 - 1
luckypot_sp/assets/SubGame/slotNTigerbundle/script/FortuneTigerAutoModel.ts

@@ -47,7 +47,8 @@ export default class FortuneTigerAutoModel {
 
         if (!this.isAuto) return false;
         if (userCoin < this.bet) {
-            cc.director.emit("showNoMoneyTip");
+            // cc.director.emit("showNoMoneyTip");
+            this.frame.showLowLackMoney()
             return false;
         }
         if (this.round <= 0) return;

+ 6 - 3
luckypot_sp/assets/SubGame/slotRabbitbundle/script/RabbitGameFrameView.ts

@@ -391,7 +391,8 @@ export default class RabbitGameFrameView extends cc.Component {
             let score = Global.getInstance().balanceTotal - this.curBetScore;
             if (score < 0) {
                 AudioPlayer.playEffect("sound/moneyless");
-                cc.director.emit("showNoMoneyTip");
+                // cc.director.emit("showNoMoneyTip");
+                this.frame.showLowLackMoney()
                 return;
             }
 
@@ -439,7 +440,8 @@ export default class RabbitGameFrameView extends cc.Component {
         let score = Global.getInstance().balanceTotal - this.curBetScore;
         if (score < 0) {
             AudioPlayer.playEffect("sound/moneyless", false);
-            cc.director.emit("showNoMoneyTip");
+            // cc.director.emit("showNoMoneyTip");
+            this.frame.showLowLackMoney()
             return;
         }
 
@@ -913,7 +915,8 @@ export default class RabbitGameFrameView extends cc.Component {
             this.comp_iconView.repeatIconAnima(this.isSpeedUp);
         } else {
             AudioPlayer.playEffect("sound/moneyless");
-            cc.director.emit("showNoMoneyTip");
+            // cc.director.emit("showNoMoneyTip");
+            this.frame.showLowLackMoney()
         }
     }
 

+ 12 - 2
luckypot_sp/assets/SubGame/slotRabbitbundle/script/RabbitSpinBtn.ts

@@ -10,14 +10,24 @@ export default class RabbitSpinBtn extends cc.Component {
 
     private rotateSpeed: number = 110;
 
+    private isDanji:boolean = false;
+
     setNormalAnima() {
-        this.rotateSpeed = 110;
-        this.sp_spin.setAnimation(0, 'changtai', true);
+        if (this.isDanji) {
+        } else {
+            this.rotateSpeed = 110;
+            this.sp_spin.setAnimation(0, 'changtai', true);
+        }
     }
 
     setTurn() {
+        this.isDanji = true;
         this.rotateSpeed = 500;
         this.sp_spin.setAnimation(0, 'dianji', false);
+        this.sp_spin.setCompleteListener(()=>{
+            this.isDanji = false;
+            this.setNormalAnima();
+        })
     }
 
     setOpacity(b: boolean) {