Browse Source

升级选择新手引导防止玩家点击过快

huangxiaoyue 1 year ago
parent
commit
6a7bd92afe
1 changed files with 6 additions and 0 deletions
  1. 6 0
      GameClient/Assets/Game/HotUpdate/Views/Card/CardUpLevelView.cs

+ 6 - 0
GameClient/Assets/Game/HotUpdate/Views/Card/CardUpLevelView.cs

@@ -60,6 +60,9 @@ namespace GFGGame
         protected override void OnShown()
         {
             base.OnShown();
+            //防止引导检测之前触发点击事件
+            GRoot.inst.touchable = false;
+
             _cardData = (CardData)this.viewData;
             AddEffect();
             ClearItemsCountList();
@@ -165,6 +168,8 @@ namespace GFGGame
 
         protected override void OnHide()
         {
+            GRoot.inst.touchable = true;
+
             base.OnHide();
             Timers.inst.Remove(CheckGuide);
         }
@@ -263,6 +268,7 @@ namespace GFGGame
 
         private void CheckGuide(object param)
         {
+            GRoot.inst.touchable = true;
             if (GuideDataManager.IsGuideFinish(ConstGuideId.UP_CARD_LV) <= 0)
             {
                 UpdateToCheckGuide(null);