Browse Source

商城特效报错问题

huangxiaoyue 1 year ago
parent
commit
6314143a87

+ 1 - 0
GameClient/Assets/Game/HotUpdate/Data/ShopViewManager.cs

@@ -82,6 +82,7 @@ namespace GFGGame
             {
                 EffectUI _effectUI = EffectUIPool.CreateEffectUI(item.m_holderfEff, "ui_Small_parts", "store_Value");
                 _effectUIs.Add(_effectUI);
+                item.m_holderfEff.visible = shopCfg.price < shopCfg.originalPrice;
             }
             item.m_txtDesc.text = shopCfg.price <= 0 ? "" : ShopDataManager.Instance.GetShopGoodsDiscount(shopCfg.id).ToString();
 

+ 3 - 3
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Store/UI_ListShopItem.cs

@@ -10,9 +10,9 @@ namespace UI.Store
         public Controller m_c1;
         public Controller m_c2;
         public GImage m_imgDouble;
+        public GGroup m_grpDiscount;
         public GGraph m_holderfEff;
         public GTextField m_txtDesc;
-        public GGroup m_grpDiscount;
         public GLoader m_icon;
         public GTextField m_txtName;
         public GTextField m_txtEndTime;
@@ -69,9 +69,9 @@ namespace UI.Store
             m_c1 = comp.GetController("c1");
             m_c2 = comp.GetController("c2");
             m_imgDouble = (GImage)comp.GetChild("imgDouble");
+            m_grpDiscount = (GGroup)comp.GetChild("grpDiscount");
             m_holderfEff = (GGraph)comp.GetChild("holderfEff");
             m_txtDesc = (GTextField)comp.GetChild("txtDesc");
-            m_grpDiscount = (GGroup)comp.GetChild("grpDiscount");
             m_icon = (GLoader)comp.GetChild("icon");
             m_txtName = (GTextField)comp.GetChild("txtName");
             m_txtEndTime = (GTextField)comp.GetChild("txtEndTime");
@@ -84,9 +84,9 @@ namespace UI.Store
             m_c1 = null;
             m_c2 = null;
             m_imgDouble = null;
+            m_grpDiscount = null;
             m_holderfEff = null;
             m_txtDesc = null;
-            m_grpDiscount = null;
             m_icon = null;
             m_txtName = null;
             m_txtEndTime = null;