瀏覽代碼

会员中心红点

zhaoyang 2 年之前
父節點
當前提交
62a65fd487

+ 2 - 2
FGUIProject/assets/Store/components/ListGiftItem.xml

@@ -12,8 +12,8 @@
     <image id="n22_10not" name="n22" src="hhx91f" fileName="imagesNew/GiftBag_baseboard1.png" xy="26,0"/>
     <image id="n22_10not" name="n22" src="hhx91f" fileName="imagesNew/GiftBag_baseboard1.png" xy="26,0"/>
     <image id="n47_l500" name="imgDouble" src="hhx9v" fileName="imagesNew/font_save_baseboard.png" xy="0,-1" group="n26_10not"/>
     <image id="n47_l500" name="imgDouble" src="hhx9v" fileName="imagesNew/font_save_baseboard.png" xy="0,-1" group="n26_10not"/>
     <text id="n48_l500" name="n48" xy="17,7" size="69,46" group="n26_10not" fontSize="34" color="#ffffff" letterSpacing="-2" text="超值"/>
     <text id="n48_l500" name="n48" xy="17,7" size="69,46" group="n26_10not" fontSize="34" color="#ffffff" letterSpacing="-2" text="超值"/>
-    <text id="n49_l500" name="txtDesc" xy="8,32" pivot="0.5,0" size="55,51" group="n51_l500" fontSize="38" color="#ffffff" align="center" letterSpacing="-2" strokeColor="#cc3300" text="800"/>
-    <text id="n50_l500" name="n50" xy="63,42" size="22,36" group="n51_l500" fontSize="26" color="#ffffff" letterSpacing="-2" text="%"/>
+    <text id="n49_l500" name="txtDesc" xy="8,32" pivot="0.5,0" size="55,51" group="n51_l500" fontSize="38" color="#ffffff" align="center" letterSpacing="-2" strokeColor="#e4622d" strokeSize="2" text="800"/>
+    <text id="n50_l500" name="n50" xy="63,42" size="22,36" group="n51_l500" fontSize="26" color="#ffffff" letterSpacing="-2" strokeColor="#e4622d" strokeSize="2" text="%"/>
     <group id="n51_l500" name="n51" xy="8,32" size="77,51" group="n26_10not" advanced="true" layout="hz" excludeInvisibles="true">
     <group id="n51_l500" name="n51" xy="8,32" size="77,51" group="n26_10not" advanced="true" layout="hz" excludeInvisibles="true">
       <relation target="" sidePair="center-center"/>
       <relation target="" sidePair="center-center"/>
     </group>
     </group>

+ 3 - 3
FGUIProject/assets/Store/components/ListShopItem.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <?xml version="1.0" encoding="utf-8"?>
 <component size="290,455" overflow="hidden">
 <component size="290,455" overflow="hidden">
-  <controller name="c1" alias="礼包购买状态" pages="0,,1," selected="1">
+  <controller name="c1" alias="礼包购买状态" pages="0,,1," selected="0">
     <remark page="0" value="可购买"/>
     <remark page="0" value="可购买"/>
     <remark page="1" value="已售罄"/>
     <remark page="1" value="已售罄"/>
   </controller>
   </controller>
@@ -13,8 +13,8 @@
     <image id="n55_l500" name="n55" src="fqortau" fileName="imagesNew/sc_xian.png" xy="27,119" size="236,4"/>
     <image id="n55_l500" name="n55" src="fqortau" fileName="imagesNew/sc_xian.png" xy="27,119" size="236,4"/>
     <image id="n47_l500" name="imgDouble" src="hhx9v" fileName="imagesNew/font_save_baseboard.png" xy="191,263" group="n26_10not"/>
     <image id="n47_l500" name="imgDouble" src="hhx9v" fileName="imagesNew/font_save_baseboard.png" xy="191,263" group="n26_10not"/>
     <text id="n48_l500" name="n48" xy="208,271" size="69,46" group="n26_10not" fontSize="34" color="#ffffff" letterSpacing="-2" text="超值"/>
     <text id="n48_l500" name="n48" xy="208,271" size="69,46" group="n26_10not" fontSize="34" color="#ffffff" letterSpacing="-2" text="超值"/>
-    <text id="n49_l500" name="txtDesc" xy="207,301" pivot="0.5,0" size="55,51" group="n51_l500" fontSize="38" color="#ffffff" align="center" letterSpacing="-2" strokeColor="#cc3300" text="800"/>
-    <text id="n50_l500" name="n50" xy="262,310" size="22,36" group="n51_l500" fontSize="26" color="#ffffff" letterSpacing="-2" text="%"/>
+    <text id="n49_l500" name="txtDesc" xy="207,301" pivot="0.5,0" size="55,51" group="n51_l500" fontSize="38" color="#ffffff" align="center" letterSpacing="-2" strokeColor="#e4622d" strokeSize="2" text="800"/>
+    <text id="n50_l500" name="n50" xy="262,310" size="22,36" group="n51_l500" fontSize="26" color="#ffffff" letterSpacing="-2" strokeColor="#e4622d" strokeSize="2" text="%"/>
     <group id="n51_l500" name="n51" xy="207,301" size="77,51" group="n26_10not" advanced="true" layout="hz" excludeInvisibles="true">
     <group id="n51_l500" name="n51" xy="207,301" size="77,51" group="n26_10not" advanced="true" layout="hz" excludeInvisibles="true">
       <relation target="" sidePair="center-center"/>
       <relation target="" sidePair="center-center"/>
     </group>
     </group>

+ 7 - 4
GameClient/Assets/Game/HotUpdate/Data/RedDotDataManager.cs

@@ -34,7 +34,7 @@ namespace GFGGame
             {
             {
                 return true;
                 return true;
             }
             }
-            if(TaskDataManager.Instance.CheckTaskRewardCanGet(TaskType.Daily))
+            if (TaskDataManager.Instance.CheckTaskRewardCanGet(TaskType.Daily))
             {
             {
                 return true;
                 return true;
             }
             }
@@ -51,9 +51,9 @@ namespace GFGGame
         {
         {
             //任务奖励
             //任务奖励
             var currentDay = ActivityDay7DataManager.Instance.GetActivityDay7Day();
             var currentDay = ActivityDay7DataManager.Instance.GetActivityDay7Day();
-            for(var day = currentDay; day > 0; day--)
+            for (var day = currentDay; day > 0; day--)
             {
             {
-                if(ActivityDay7DataManager.Instance.CheckActivityDay7TaskRewrdCanGetByDay(day))
+                if (ActivityDay7DataManager.Instance.CheckActivityDay7TaskRewrdCanGetByDay(day))
                 {
                 {
                     return true;
                     return true;
                 }
                 }
@@ -62,7 +62,7 @@ namespace GFGGame
             var activity7DaysCfgs = Activity7DaysCfgArray.Instance.dataArray;
             var activity7DaysCfgs = Activity7DaysCfgArray.Instance.dataArray;
             foreach (var cfg in activity7DaysCfgs)
             foreach (var cfg in activity7DaysCfgs)
             {
             {
-                if(ActivityDay7DataManager.Instance.CheckActivityDay7RewardCanGet(cfg.id))
+                if (ActivityDay7DataManager.Instance.CheckActivityDay7RewardCanGet(cfg.id))
                 {
                 {
                     return true;
                     return true;
                 }
                 }
@@ -367,6 +367,9 @@ namespace GFGGame
             return GameGlobal.myNumericComponent.GetAsInt(NumericType.VipWeekGetStatus) == 0 &&
             return GameGlobal.myNumericComponent.GetAsInt(NumericType.VipWeekGetStatus) == 0 &&
                    RoleDataManager.vipLv > 0;
                    RoleDataManager.vipLv > 0;
         }
         }
+
+
+
         //商店-礼包-活动礼包
         //商店-礼包-活动礼包
         public bool GetGiftBagRewardRed()
         public bool GetGiftBagRewardRed()
         {
         {

+ 33 - 2
GameClient/Assets/Game/HotUpdate/Views/Store/StoreChargeAddUpView.cs

@@ -69,6 +69,7 @@ namespace GFGGame
         {
         {
             base.AddEventListener();
             base.AddEventListener();
             EventAgent.AddEventListener(ConstMessage.NUMERIC_CHANGE, RefreshList);
             EventAgent.AddEventListener(ConstMessage.NUMERIC_CHANGE, RefreshList);
+            EventAgent.AddEventListener(ConstMessage.NUMERIC_CHANGE, UpdateRedDot);
         }
         }
         protected override void OnShown()
         protected override void OnShown()
         {
         {
@@ -80,6 +81,7 @@ namespace GFGGame
             _ui.m_list.selectedIndex = _curSelectIndex;
             _ui.m_list.selectedIndex = _curSelectIndex;
             _ui.m_list.ScrollToView(_curSelectIndex);
             _ui.m_list.ScrollToView(_curSelectIndex);
             ShopViewManager.Instance.UpdateVipProgressCom(_ui.m_comVipLv.target);
             ShopViewManager.Instance.UpdateVipProgressCom(_ui.m_comVipLv.target);
+            UpdateRedDot();
         }
         }
 
 
         protected override void OnHide()
         protected override void OnHide()
@@ -228,14 +230,15 @@ namespace GFGGame
             if (_curSelectIndex == 0) return;
             if (_curSelectIndex == 0) return;
             _curSelectIndex = _curSelectIndex - 1;
             _curSelectIndex = _curSelectIndex - 1;
             _ui.m_list.ScrollToView(_curSelectIndex, true);
             _ui.m_list.ScrollToView(_curSelectIndex, true);
-            // _ui.m_list.selectedIndex = _curSelectIndex;
+            UpdateRedDot();
         }
         }
         private void OnBtnRightClick()
         private void OnBtnRightClick()
         {
         {
             if (_curSelectIndex == _ui.m_list.numItems - 1) return;
             if (_curSelectIndex == _ui.m_list.numItems - 1) return;
             _curSelectIndex = _curSelectIndex + 1;
             _curSelectIndex = _curSelectIndex + 1;
             _ui.m_list.ScrollToView(_curSelectIndex, true);
             _ui.m_list.ScrollToView(_curSelectIndex, true);
-            // _ui.m_list.selectedIndex = _curSelectIndex;
+            UpdateRedDot();
+
         }
         }
         private void UpdateSuitView()
         private void UpdateSuitView()
         {
         {
@@ -243,6 +246,34 @@ namespace GFGGame
             _ui.m_list.selectedIndex = _curSelectIndex;
             _ui.m_list.selectedIndex = _curSelectIndex;
         }
         }
 
 
+        private void UpdateRedDot()
+        {
+
+            bool leftRed = false;
+            bool rightRed = false;
+            VipCfg[] vipCfgs = VipCfgArray.Instance.dataArray;
+            for (int i = 1; i < vipCfgs.Length; i++)
+            {
+                bool isGet = MathHelper.isBitSet(GameGlobal.myNumericComponent.GetAsInt(NumericType.VipGetStatus), vipCfgs[i].id);
+                bool red = !isGet && RoleDataManager.vipLv >= vipCfgs[i].id;
+
+                if (red && _curSelectIndex > i - 1)
+                {
+                    leftRed = true;
+                    break;
+                }
+                if (red && _curSelectIndex + 1 < i)
+                {
+                    rightRed = true;
+                    break;
+                }
+            }
+
+            if (GameGlobal.myNumericComponent.GetAsInt(NumericType.VipWeekGetStatus) == 0 && RoleDataManager.vipLv > 0 && _curSelectIndex > RoleDataManager.vipLv - 1) { leftRed = true; }
+            if (GameGlobal.myNumericComponent.GetAsInt(NumericType.VipWeekGetStatus) == 0 && RoleDataManager.vipLv > 0 && _curSelectIndex + 1 < RoleDataManager.vipLv) { rightRed = true; }
+            RedDotController.Instance.SetComRedDot(_ui.m_btnLeft, leftRed);
+            RedDotController.Instance.SetComRedDot(_ui.m_btnRight, rightRed);
 
 
+        }
     }
     }
 }
 }

+ 6 - 0
GameClient/Assets/Game/HotUpdate/Views/Store/StoreView.cs

@@ -202,6 +202,12 @@ namespace GFGGame
         private void UpdateRedDot()
         private void UpdateRedDot()
         {
         {
             RedDotController.Instance.SetComRedDot(_ui.m_comTab.m_btn0.target, RedDotDataManager.Instance.GetChargeAddUpRewardRed());
             RedDotController.Instance.SetComRedDot(_ui.m_comTab.m_btn0.target, RedDotDataManager.Instance.GetChargeAddUpRewardRed());
+
+            for (int i = 0; i < _ui.m_listSubTab.numItems; i++)
+            {
+                RedDotController.Instance.SetComRedDot(_ui.m_listSubTab.GetChildAt(i).asCom, false);
+            }
+
             if (_ui.m_comTab.m_c1.selectedIndex == ConstStoreTabId.STORE_CHARGE)
             if (_ui.m_comTab.m_c1.selectedIndex == ConstStoreTabId.STORE_CHARGE)
             {
             {
                 RedDotController.Instance.SetComRedDot(_ui.m_listSubTab.GetChildAt(ConstStoreSubId.STORE_CHARGE_ADDUP).asCom, RedDotDataManager.Instance.GetChargeAddUpRewardRed());
                 RedDotController.Instance.SetComRedDot(_ui.m_listSubTab.GetChildAt(ConstStoreSubId.STORE_CHARGE_ADDUP).asCom, RedDotDataManager.Instance.GetChargeAddUpRewardRed());

二進制
GameClient/Assets/ResIn/UI/Store/Store_fui.bytes