Просмотр исходного кода

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

guodong 1 год назад
Родитель
Сommit
118b48b03d

+ 4 - 0
GameClient/Assets/Game/HotUpdate/Data/MiniGameDateManager.cs

@@ -18,6 +18,10 @@ namespace GFGGame
 
         public bool GetRewardRot()
         {
+            if(gameinfoList.Count == 0)
+            {
+                return false;
+            }
             foreach(GameInfoProto t in gameinfoList)
             {
                 if(t.FirstPassRewardStatus == 1)

+ 4 - 3
GameClient/Assets/Game/HotUpdate/Data/RoleDataManager.cs

@@ -373,9 +373,10 @@ namespace GFGGame
         /// <param name="dressUpBgID"></param>
         public static void CheckSaveDressUpBgToMainBg(int dressUpBgID)
         {
-            // 小月卡
-            float endTime = GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardGoldEndTime);
-            if (endTime > TimeHelper.ServerNow() && saveDressUpBgToMainBg == 1)
+            bool canChange =
+                GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardGoldEndTime) > TimeHelper.ServerNow()
+                || GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardBlackGoldEndTime) > TimeHelper.ServerNow();
+            if (canChange && saveDressUpBgToMainBg == 1)
             {
                 SaveMainBgID(dressUpBgID);
             }

+ 3 - 2
GameClient/Assets/Game/HotUpdate/Views/MainUI/MainUIView.cs

@@ -940,7 +940,8 @@ namespace GFGGame
             //海之市
             if (redPointUpdateFrame == 18)
             {
-                RedDotController.Instance.SetComRedDot(_ui.m_btnHaiZhiShi.target, RedDotDataManager.Instance.GetFieldRed(), "icon_tanhao", -39, 15);
+                RedDotController.Instance.SetComRedDot(_ui.m_btnHaiZhiShi.target, RedDotDataManager.Instance.GetTravelRed() 
+                    ||RedDotDataManager.Instance.GetFieldRed(), "icon_tanhao", -39, 15);
             }
 
             // 新春活动
@@ -1190,7 +1191,7 @@ namespace GFGGame
 
         //private void OnClickBtnGetYuanXiao()
         //{
-        //    ViewManager.Show<ActivityGetYuanXiaoView>();
+        //    ViewManager.Show<ActivityGetYuanXiaoEntryView>();
         //}
     }
 }

+ 28 - 8
GameClient/Assets/Game/HotUpdate/Views/MiniGame/FlipGameView.cs

@@ -121,6 +121,8 @@ namespace GFGGame
             Timers.inst.Remove(UpdateHit);
             Timers.inst.Remove(StartTime);
             Timers.inst.Remove(UpdateOneHit);
+            Timers.inst.Remove(FlipAllCard);
+            Timers.inst.Remove(ResetTouch);
             base.OnHide();
 
         }
@@ -189,7 +191,7 @@ namespace GFGGame
                 cardItem.target.onClick.Add(OnClickCardItem);
             }
             Card _c1 = (Card)cardItem.m_card;
-            _c1.opened = false;
+            _c1.opened = true;
             _c1.SetPerspective();
 
             itemInfo.Add("index", index);
@@ -239,23 +241,19 @@ namespace GFGGame
             _ui.m_star1.SetPosition(((float)(gameTime - CustemsNum[0]) / (float)gameTime) * _ui.m_ScareBar.width + 70, _ui.m_star1.position.y, _ui.m_star1.position.z);
             _ui.m_star2.SetPosition(((float)(gameTime - CustemsNum[1]) / (float)gameTime) * _ui.m_ScareBar.width + 10, _ui.m_star1.position.y, _ui.m_star1.position.z);
             _ui.m_star3.SetPosition(((float)(gameTime - CustemsNum[2]) / (float)gameTime) * _ui.m_ScareBar.width, _ui.m_star1.position.y, _ui.m_star1.position.z);
-
             _ui.m_title.visible = false;
             _ui.m_titleEffec.visible = true;
             _ui.m_barEffect.x = _ui.m_ScareBar.width;
 
-            _ui.m_cardList.touchable = true;
-            //计时器
-            Timers.inst.Add(1.0f, 0, UpdateTime);
-            //进度条计时器
-            Timers.inst.Add(0.1f, 0, UpdateBar);
+            _ui.m_cardList.touchable = false;
         }
 
         private void UpdateList()
-
         {
             _ui.m_cardList.columnCount = columns;
             _ui.m_cardList.numItems = cardNum;
+            //翻转所有牌
+            Timers.inst.Add(1.0f, 1, FlipAllCard);
         }
         private void OnClickCardItem(EventContext context)
         {
@@ -403,6 +401,28 @@ namespace GFGGame
             _ui.m_cardList.touchable = true;
             Timers.inst.Remove(UpdateOneHit);
         }
+
+        private void FlipAllCard(object param = null)
+        {
+            //计时器
+            Timers.inst.Add(1.0f, 0, UpdateTime);
+            //进度条计时器
+            Timers.inst.Add(0.1f, 0, UpdateBar);
+            for (int i = 0; i < cardNum; i++)
+            {
+                UI_cardItem item = UI_cardItem.Proxy(_ui.m_cardList.GetChildAt(i));
+                //翻回去
+                Card card = (Card)item.m_card;
+                card.Turn();
+                UI_cardItem.ProxyEnd();
+            }
+            Timers.inst.Add(0.6f, 1, ResetTouch);
+        }
+
+        private void ResetTouch(object param = null)
+        {
+            _ui.m_cardList.touchable = true;
+        }
         private void UpdateTime(object param = null)
         {
             timeIndex++;

+ 4 - 3
GameClient/Assets/Game/HotUpdate/Views/RoleInfo/MainBgChooseView.cs

@@ -184,9 +184,10 @@ namespace GFGGame
 
         private void OnBtnSaveDressUpBgClick()
         {
-            // 小月卡
-            float endTime = GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardGoldEndTime);
-            if (endTime > TimeHelper.ServerNow())
+            bool canChange =
+                GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardGoldEndTime) > TimeHelper.ServerNow()
+                || GameGlobal.myNumericComponent.GetAsLong(NumericType.MonthCardBlackGoldEndTime) > TimeHelper.ServerNow();
+            if (canChange)
             {
                 if (RoleDataManager.saveDressUpBgToMainBg == 0)
                 {

BIN
GameClient/Assets/ResIn/UI/MiniGame/MiniGame_fui.bytes