瀏覽代碼

茶话会增加进入前弹窗提示

huangxiaoyue 1 年之前
父節點
當前提交
7536793f24

+ 3 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/League/UI_LeagueAnswerUI.cs

@@ -16,6 +16,7 @@ namespace UI.League
         public GTextField m_txtTime;
         public GButton m_btnAnswer;
         public GTextField m_txtPlayRule;
+        public GButton m_btnTeaParty;
         public const string URL = "ui://tw70qm9dpvb452";
         public const string PACKAGE_NAME = "League";
         public const string RES_NAME = "LeagueAnswerUI";
@@ -72,6 +73,7 @@ namespace UI.League
             m_txtTime = (GTextField)comp.GetChild("txtTime");
             m_btnAnswer = (GButton)comp.GetChild("btnAnswer");
             m_txtPlayRule = (GTextField)comp.GetChild("txtPlayRule");
+            m_btnTeaParty = (GButton)comp.GetChild("btnTeaParty");
         }
         public void Dispose(bool disposeTarget = false)
         {
@@ -85,6 +87,7 @@ namespace UI.League
             m_txtTime = null;
             m_btnAnswer = null;
             m_txtPlayRule = null;
+            m_btnTeaParty = null;
             if(disposeTarget && target != null)
             {
                 target.RemoveFromParent();

+ 11 - 0
GameClient/Assets/Game/HotUpdate/Views/League/LeagueAnswerView.cs

@@ -37,6 +37,7 @@ namespace GFGGame
             _ui.m_btnClose.onClick.Add(Hide);
             _ui.m_btnRank.onClick.Add(OnBtnRankClick);
             _ui.m_btnAnswer.onClick.Add(OnBtnAnswerClick);
+            _ui.m_btnTeaParty.onClick.Add(OnBtnTeaPartyClick);
         }
 
         protected override void AddEventListener()
@@ -53,6 +54,7 @@ namespace GFGGame
                 _ui.m_c1.selectedIndex = index;
                 var openCfg = TeapartyOpenCfgArray.Instance.GetCfg(LeagueDataManager.Instance.TeaPartyId);
                 _ui.m_txtPlayRule.text =  TextDescCfgArray.Instance.GetCfg(300023).text + openCfg.preview;
+                _ui.m_btnTeaParty.visible = LeagueDataManager.Instance.TeaPartyStatus != 0;
             }
             else {
                 _ui.m_c1.selectedIndex = 0;
@@ -82,6 +84,15 @@ namespace GFGGame
             ViewManager.Show<LeagueAnsweringView>(null, new object[] { });
         }
 
+        private void OnBtnTeaPartyClick()
+        {
+            Hide();
+            if (LeagueDataManager.Instance.TeaPartyStatus == 2 && !LeagueDataManager.Instance.RoleTeapartyInfo.IsComplete && LeagueDataManager.Instance.RoleTeapartyInfo.Status)
+                ViewManager.Show<LeagueTeaPartyShowView>();
+            else
+                ViewManager.Show<LeagueTeaPartyView>();
+        }
+        
         private void UpdateView()
         {
             OtherRoleInfoData lastNO1 =

+ 1 - 6
GameClient/Assets/Game/HotUpdate/Views/League/LeagueView.cs

@@ -117,12 +117,7 @@ namespace GFGGame
         }
         private void OnBtnPartyClick()
         {
-            if (LeagueDataManager.Instance.TeaPartyStatus == 0)
-                ViewManager.Show<LeagueAnswerView>(1);
-            else if (LeagueDataManager.Instance.TeaPartyStatus == 2 && !LeagueDataManager.Instance.RoleTeapartyInfo.IsComplete)
-                ViewManager.Show<LeagueTeaPartyShowView>();
-            else
-                ViewManager.Show<LeagueTeaPartyView>();
+            ViewManager.Show<LeagueAnswerView>(1);
         }
         private void OnBtnShopClick()
         {

+ 1 - 2
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryDialogView.cs

@@ -113,7 +113,6 @@ namespace GFGGame
                 _dressUpObjUI = new DressUpObjUI();
             }
             _speedAutoPlay = FightDataManager.Instance.dialogSpeed;
-            _autoPlay = false;
             lastTextFieldType = "";
             UpdateSpeedUpBtn();
             _dialogListLookBack = new List<string>();
@@ -127,6 +126,7 @@ namespace GFGGame
             }
 
             IsTeaParty = (bool)datas[4];
+            _autoPlay = IsTeaParty;
 
             if (LauncherConfig.netType == LauncherConfig.EnumNetType.TEMP && !InstanceZonesDataManager.CheckLevelPass(MainStoryDataManager.currentLevelCfgId))
             {
@@ -156,7 +156,6 @@ namespace GFGGame
 
             if (IsTeaParty) {
                 _ui.m_c1.selectedIndex = 2;
-                _autoPlay = true;
             }
 
             _ui.m_btnBack.visible = InstanceZonesDataManager.CheckLevelPass(100001001);

二進制
GameClient/Assets/ResIn/UI/League/League_fui.bytes