Browse Source

Merge branch 'master' of http://10.108.64.190:3000/gfg/client

guodong 1 năm trước cách đây
mục cha
commit
e6de3c8184

+ 0 - 1
GameClient/Assets/Game/HotUpdate/ServerProxy/MiniGameProxy.cs

@@ -8,7 +8,6 @@ namespace GFGGame
         {
             var response = await MessageHelper.SendToServer(new C2S_MiniGameStart { GameId = gameID,GameType = gameType,ActivityId = activityId });
             if (!(response is { Error: ErrorCode.ERR_Success })) return false;
-            EventAgent.DispatchEvent(ConstMessage.MINI_GAME_UPDATE);
             return true;
         }
 

+ 13 - 4
GameClient/Assets/Game/HotUpdate/Views/ActivityAfternoonTea/ActivitySyntheticView.cs

@@ -1,7 +1,3 @@
-using System.Collections;
-using System.Collections.Generic;
-using UnityEngine;
-using UI.DressUp;
 using FairyGUI;
 using UI.ActivityAfternoonTea;
 using UI.CommonGame;
@@ -55,6 +51,14 @@ namespace GFGGame
             _ui.m_listSynthetic.numItems = _suitCfg.partsArr.Length;
             RefreshTimeText();
             _ui.m_txtTips.SetVar("name", _suitCfg.name).FlushVars();
+            Timers.inst.Add(1, 0, UpdateTime);
+        }
+
+        protected override void OnHide()
+        {
+            base.OnHide();
+
+            Timers.inst.Remove(UpdateTime);
         }
 
         private void OnClickBtnBack()
@@ -62,6 +66,11 @@ namespace GFGGame
             ViewManager.GoBackFrom(typeof(ActivitySyntheticView).FullName);
         }
 
+        private void UpdateTime(object param)
+        {
+            RefreshTimeText();
+        }
+
         private void RefreshTimeText()
         {
             ActivityOpenCfg activityOpenCfg = ActivityOpenCfgArray.Instance.GetCfg(5005);

+ 1 - 2
GameClient/Assets/Game/HotUpdate/Views/ActivityHuaRongDao/ActivityHuaRongDaoEntryView.cs

@@ -51,8 +51,7 @@ namespace GFGGame
             base.OnShown();
 
             _ui.m_hide.Play();
-            _activityID = 5003;
-            //_activityID = (int)viewData;
+            _activityID = (int)viewData;
             await InitInfo();
             _ui.m_show.Play();
             UpdateTime(null);

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/ActivityHuaRongDao/ActivityHuaRongDaoView.cs

@@ -192,8 +192,8 @@ namespace GFGGame
 
                     lastPos = zeroPos;
                     zeroPos = tempPos;
+                    ++num;
                 }
-                ++num;
             }
             return list;
         }