zhaoyang 3 éve
szülő
commit
907f8ba3d9

+ 1 - 0
FGUIProject/assets/CommonGame/components/ComItem.xml

@@ -5,6 +5,7 @@
     <loader id="n12_ehs9" name="loaIcon" xy="112,96" pivot="0.5,0.5" anchor="true" size="150,150" group="n21_qr4e" aspect="true" url="ui://eg2y0ldpm9wm8v" fill="scale"/>
     <text id="n14_ehs9" name="txtName" xy="111,194" pivot="0.5,0" anchor="true" size="228,44" group="n21_qr4e" fontSize="32" color="#9b7f61" text="赵钱孙李·巴拉"/>
     <image id="n16_j8b3" name="imgGot" src="j48o9b" fileName="images/yx_yilq.png" xy="23,80" group="n21_qr4e"/>
+    <image id="n22_cs8j" name="imgNotGot" src="cs8jthw" fileName="images/yx_wilq.png" xy="21,83" group="n21_qr4e"/>
     <text id="n17_j48o" name="txtHasCount" xy="112,243" pivot="0.5,0" anchor="true" size="105,36" group="n21_qr4e" fontSize="26" color="#a28d77" vars="true" text="已拥有:{count=0}"/>
     <loader id="n18_j48o" name="loaRarity" xy="164,0" size="44,94" group="n21_qr4e" url="ui://eg2y0ldpd4iw52" autoSize="true"/>
     <loader id="n19_tc53" name="loaShouTongReward" xy="32,81" size="160,40" group="n21_qr4e" url="ui://eg2y0ldptc539z" autoSize="true"/>

BIN
FGUIProject/assets/CommonGame/images/yx_wilq.png


+ 1 - 0
FGUIProject/assets/CommonGame/package.xml

@@ -196,6 +196,7 @@
     <image id="qr4etht" name="wpzs_anniu_2.png" path="/imagesExport/" exported="true"/>
     <image id="qr4ethu" name="tjtj_bjbj.jpg" path="/bgimg/" exported="true" atlas="alone_npot"/>
     <image id="a97wthv" name="huoyuedu.png" path="/imagesExport/" exported="true"/>
+    <image id="cs8jthw" name="yx_wilq.png" path="/images/"/>
   </resources>
   <publish name="" path="..\GameClient\Assets\ResIn\UI\CommonGame" packageCount="2" genCode="true" extractAlpha="true"/>
 </packageDescription>

+ 5 - 6
FGUIProject/assets/FieldGuide/SuitPartsDetailUI.xml

@@ -1,12 +1,12 @@
 <?xml version="1.0" encoding="utf-8"?>
-<component size="912,834">
+<component size="936,783">
   <displayList>
-    <loader id="n0_pjip" name="bg" xy="0,0" size="912,834" url="ui://mk0fwx0xq08x4" fill="scaleFree">
+    <loader id="n0_pjip" name="bg" xy="0,0" size="936,783" url="ui://mk0fwx0xlwri5u" fill="scaleFree">
       <relation target="" sidePair="width-width,height-height"/>
     </loader>
-    <image id="n1_pjip" name="n1" src="ga16f" fileName="imagesExport/zx_jq_djdikbti.png" pkg="eg2y0ldp" xy="9,8"/>
-    <text id="n2_pjip" name="txtTitle" xy="93,22" size="726,56" fontSize="42" color="#ffffff" align="center" autoSize="none" text="套装详情"/>
-    <list id="n3_pjip" name="listParts" xy="44,125" size="841,664" layout="flow_hz" overflow="scroll" colGap="22" defaultItem="ui://vqq9h9h4pjip19" autoClearItems="true">
+    <image id="n4_cs8j" name="n4" src="kztethr" fileName="imagesExport/hyhy_btbt_1.png" pkg="eg2y0ldp" xy="230,32"/>
+    <text id="n2_pjip" name="txtTitle" xy="104,36" size="726,72" fontSize="54" color="#8f6e30" align="center" autoSize="none" text="套装详情"/>
+    <list id="n3_pjip" name="listParts" xy="24,179" size="887,540" layout="flow_hz" overflow="scroll" lineGap="-30" defaultItem="ui://eg2y0ldpj48o98" autoClearItems="true">
       <item/>
       <item/>
       <item/>
@@ -15,5 +15,4 @@
       <item/>
     </list>
   </displayList>
-  <relation target="n3_pjip" sidePair="height-height"/>
 </component>

+ 18 - 0
GameClient/Assets/Game/HotUpdate/Views/CommonGame/ItemView.cs

@@ -10,6 +10,7 @@ namespace GFGGame
         private GTextField _txtCount;
         private GTextField _txtHasCount;
         private GImage _imgGot;
+        private GImage _imgNotGot;
         private GLoader _loaShouTongRewardVisble;
         private GGroup _grpCount;
 
@@ -24,6 +25,7 @@ namespace GFGGame
             _txtCount = obj.GetChild("txtCount") as GTextField;
             _txtHasCount = obj.GetChild("txtHasCount") as GTextField;
             _imgGot = obj.GetChild("imgGot") as GImage;
+            _imgNotGot = obj.GetChild("imgNotGot") as GImage;
             _loaShouTongRewardVisble = obj.GetChild("loaShouTongReward") as GLoader;
             _grpCount = obj.GetChild("grpCount") as GGroup;
             AddClickListener();
@@ -49,6 +51,7 @@ namespace GFGGame
             _loaIcon.url = ResPathUtil.GetIconPath(itemCfg);
             RarityIconController.UpdateRarityIcon(_loaRarity, _itemData.id, false);
             _imgGot.visible = false;
+            _imgNotGot.visible = false;
             _loaShouTongRewardVisble.visible = false;
             _grpCount.visible = true;
             _showTips = true;
@@ -73,6 +76,21 @@ namespace GFGGame
                 _imgGot.visible = value;
             }
         }
+        /// <summary>
+        /// “未领取”显示状态
+        /// </summary>
+        /// <value></value>
+        public bool ImgNotGotVisible
+        {
+            get
+            {
+                return _imgNotGot.visible;
+            }
+            set
+            {
+                _imgNotGot.visible = value;
+            }
+        }
 
         /// <summary>
         /// "已拥有"显示状态

+ 10 - 16
GameClient/Assets/Game/HotUpdate/Views/FieldGuide/SuitPartsDetailView.cs

@@ -24,7 +24,7 @@ namespace GFGGame
             this.viewCom.Center();
 
             _ui.m_listParts.itemRenderer = ListPartsItemRenderer;
-            _ui.m_listParts.onClickItem.Add(OnClickListPartsItem);
+            // _ui.m_listParts.onClickItem.Add(OnClickListPartsItem);
         }
 
         protected override void OnShown()
@@ -44,24 +44,18 @@ namespace GFGGame
             base.OnHide();
         }
 
-        private void ListPartsItemRenderer(int index, GObject item)
+        private void ListPartsItemRenderer(int index, GObject obj)
         {
-            UI_ListSuitPartsItem listItem = UI_ListSuitPartsItem.Proxy(item);
             int itemId = _items[index];
-            ItemCfg itemCfg = ItemCfgArray.Instance.GetCfg(itemId);
-            listItem.m_txtName.text = ItemUtil.GetItemName(itemId);
-            listItem.m_icon.url = ResPathUtil.GetIconPath(itemCfg);
+            ItemData reward = ItemUtil.createItemData(itemId, 1);
+            if (obj.data == null)
+            {
+                obj.data = new ItemView(obj as GComponent);
+            }
+            (obj.data as ItemView).SetData(reward);
+            (obj.data as ItemView).TxtHasCountVisble = false;
             bool haveItem = DressUpMenuItemDataManager.CheckHasItem(itemId);
-            listItem.m_imgLock.visible = listItem.m_imgLockBg.visible = !haveItem;
-            listItem.target.data = itemId;
-            // listItem.target.onClick.Clear();
-            // listItem.target.onClick.Add(() =>
-            // {
-            //     if (haveItem)
-            //     {
-            //         GoodsItemTipsController.ShowItemTips(itemId);
-            //     }
-            // });
+            (obj.data as ItemView).ImgNotGotVisible = !haveItem;
         }
         private void OnClickListPartsItem(EventContext context)
         {

BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_atlas0.png


BIN
GameClient/Assets/ResIn/UI/FieldGuide/FieldGuide_fui.bytes