Bladeren bron

茶话会开启流程修改

huangxiaoyue 1 jaar geleden
bovenliggende
commit
5c5a5a31e5

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

@@ -81,7 +81,7 @@ namespace GFGGame
         private void OnBtnAnswerClick()
         {
             Hide();
-            ViewManager.Show<LeagueAnsweringView>(null, new object[] { });
+            ViewManager.Show<LeagueAnsweringView>();
         }
 
         private void OnBtnTeaPartyClick()
@@ -90,7 +90,7 @@ namespace GFGGame
             if (LeagueDataManager.Instance.TeaPartyStatus == LeagueTeaPartyStatus.YesGo && !LeagueDataManager.Instance.RoleTeapartyInfo.IsComplete && LeagueDataManager.Instance.RoleTeapartyInfo.Status)
                 ViewManager.Show<LeagueTeaPartyShowView>();
             else
-                ViewManager.Show<LeagueTeaPartyView>();
+                ViewManager.Show<LeagueTeaPartyView>(null, new object[] { typeof(LeagueView).FullName, null });
         }
         
         private void UpdateView()

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

@@ -94,7 +94,7 @@ namespace GFGGame
 
         private void OnBtnBackClick()
         {
-            ViewManager.GoBackFrom(typeof(LeagueView).FullName);
+            ViewManager.GoBackFrom(typeof(LeagueTeaPartyOverView).FullName);
         }
 
         private void OnBtnRewardClick()

+ 7 - 7
GameClient/Assets/Game/HotUpdate/Views/League/LeagueTeaPartyShowView.cs

@@ -87,23 +87,23 @@ namespace GFGGame
 
         private void OnBtnBackClick()
         {
-            ViewManager.GoBackFrom(typeof(LeagueView).FullName);
+            ViewManager.GoBackFrom(typeof(LeagueTeaPartyShowView).FullName);
         }
 
         private void openNextView()
         {
-            if (LeagueDataManager.Instance.RoleContainerList.Count > 0)
-            {
+            //if (LeagueDataManager.Instance.RoleContainerList.Count > 0)
+            //{
                 string stroyStartID = "50001";
                 ViewManager.Show<StoryDialogView>(new object[] { stroyStartID, false, new OnCompleteStoryDialogCall(OnCompletePriorStoryDialog), null, true }, null, true);
-            }
-            else
-                ViewManager.Show<LeagueTeaPartyOverView>();
+            //}
+            //else
+            //    ViewManager.Show<LeagueTeaPartyOverView>();
         }
 
         private static void OnCompletePriorStoryDialog(bool isSkip, object param)
         {
-            ViewManager.Show<LeagueTeaPartyOverView>();
+            ViewManager.Show<LeagueTeaPartyOverView>(null, new object[] { typeof(LeagueView).FullName, null });
         }
 
         private void UpdateTime(object param)

+ 11 - 6
GameClient/Assets/Game/HotUpdate/Views/League/LeagueTeaPartyView.cs

@@ -12,6 +12,7 @@ namespace GFGGame
         private UI_LeagueTeaPartyUI _ui;
         private List<TeapartyRoleCfg> teapartyRoleCfg;
         private List<GObject> TeaPartyItemObj = new List<GObject>();
+        Dictionary<int, int> TeapartyRoleIdList = new Dictionary<int, int>();
 
         public override void Dispose()
         {
@@ -123,15 +124,18 @@ namespace GFGGame
 
             string strAlertText = "";
             var roleContainerList = LeagueDataManager.Instance.RoleContainerList;
-            List<int> TeapartyRoleIdList = new List<int>();
+            int countRoleId = 0;
+            TeapartyRoleIdList.Clear();
             foreach (var info in roleContainerList) {
-                if (info.PerNum <= 0)
-                    TeapartyRoleIdList.Add(info.TeapartyRoleId);
+                if (info.PerNum <= 0) {
+                    TeapartyRoleIdList.Add(countRoleId,info.TeapartyRoleId);
+                    countRoleId += 1;
+                }
             }
             if (TeapartyRoleIdList.Count > 0) {
                 string strRoleName = "";
-                for (int index = 1; index < TeapartyRoleIdList.Count; index++) {
-                    strRoleName = strRoleName + teapartyRoleCfg[index].name;
+                for (int index = 0; index < TeapartyRoleIdList.Count; index++) {
+                    strRoleName = strRoleName + teapartyRoleCfg[TeapartyRoleIdList[index]-1].name;
                     if (index < TeapartyRoleIdList.Count - 1)
                         strRoleName = strRoleName + "、";
                 }
@@ -152,6 +156,7 @@ namespace GFGGame
             bool result = await LeagueSproxy.TeapartyStartChallenge(RoleDataManager.roleId);
             if (result)
             {
+                _ui.m_btnChallenge.grayed = LeagueDataManager.Instance.TeaPartyStatus != LeagueTeaPartyStatus.YesOpen;
                 TeaPartyStatuChange();
             }
         }
@@ -163,7 +168,7 @@ namespace GFGGame
         
         private void OnBtnBackClick()
         {
-            ViewManager.GoBackFrom(typeof(LeagueView).FullName);
+            ViewManager.GoBackFrom(typeof(LeagueTeaPartyView).FullName);
         }
 
         private void OnBtnDetailClick(EventContext context)