فهرست منبع

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

huangxiaoyue 2 سال پیش
والد
کامیت
abfb4cf39c

+ 12 - 1
GameClient/Assets/Game/HotUpdate/ServerProxy/ActivitySProxy.cs

@@ -1,6 +1,8 @@
+using System;
 using System.Collections.Generic;
 using ET;
 using GFGGame;
+using Hutool;
 
 
 namespace GFGGame
@@ -45,7 +47,16 @@ namespace GFGGame
                     ActivityDataManager.Instance.sevenDayLoginBonusStatus = response.BonusStatus;
                     int[][] rewards = DailyLoginCfgArray.Instance.GetCfg(response.BonusId).rewardsArr;
 
-                    BonusController.TryShowBonusList(rewards);
+                    BonusController.TryShowBonusList(rewards, onSuccess: () =>
+                    {
+                        //签到完成后,关闭获得物品页面后,自动每日签到,窗口让玩家手动关闭
+                        bool isGot = MathUtil.isBitSet(GameGlobal.myNumericComponent.GetAsLong(NumericType.SignDay),
+                            TimeUtil.GetCurDay());
+                        if (!isGot)
+                        {
+                            ViewManager.Show<DailySignView>(new object[] { 1 });
+                        }
+                    });
 
                     EventAgent.DispatchEvent(ConstMessage.RED_CHANGE);
                     return true;

+ 1 - 6
GameClient/Assets/Game/HotUpdate/Views/MainUI/MainUIView.cs

@@ -215,12 +215,7 @@ namespace GFGGame
                 {
                     ViewManager.Show<SevenDayLoginView>();
                 }
-                //每日签到每天首次登录时自动弹出,并且自动签到,窗口让玩家手动关闭
-                bool isGot = MathUtil.isBitSet(GameGlobal.myNumericComponent.GetAsLong(NumericType.SignDay), TimeUtil.GetCurDay());
-                if (!isGot)
-                {
-                    ViewManager.Show<DailySignView>(new object[] { 1 });
-                }
+                
                 GameGlobal.lastLoginTime = GameGlobal.myNumericComponent.GetAsInt(NumericType.OnlineTimeSecs);
             }