浏览代码

转图集
修改一些ui适配

lzx 1 周之前
父节点
当前提交
011f8d4311

+ 1 - 1
Assets/Res/UI/BoxPanel/WidgetItemType2.prefab

@@ -842,7 +842,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
   m_AnchoredPosition: {x: 58.41, y: -21.027552}
-  m_SizeDelta: {x: 0, y: 35.3449}
+  m_SizeDelta: {x: 49, y: 35.3449}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &1507516687379950841
 CanvasRenderer:

+ 1 - 1
Assets/Res/UI/ItemDetailsPanel/ItemDetailsPanel.prefab

@@ -1208,7 +1208,7 @@ MonoBehaviour:
   m_FillOrigin: 0
   m_UseSpriteMesh: 0
   m_PixelsPerUnitMultiplier: 1
-  _icon_name: icon_eq_priest_armor3
+  _icon_name: icon_Coins_s
   isNotLoadDeftIcon: 0
   CurrSpriteAtlas: {fileID: 100100200, guid: 77f77eea85838ad4b8734050364b4892, type: 3}
   packInfo:

+ 10 - 10
Assets/Res/UI/MainHeroPanel/ItemWidgetType1.prefab

@@ -36,7 +36,7 @@ RectTransform:
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
-  m_AnchoredPosition: {x: 44.4249, y: -15.66925}
+  m_AnchoredPosition: {x: 55.7841, y: -15.66925}
   m_SizeDelta: {x: 36, y: 30}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &8870642595167346178
@@ -245,7 +245,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 0}
   m_AnchorMax: {x: 0, y: 0}
   m_AnchoredPosition: {x: 0, y: 0}
-  m_SizeDelta: {x: 26.4249, y: 26.4249}
+  m_SizeDelta: {x: 37.7841, y: 37.7841}
   m_Pivot: {x: 0, y: 0.5}
 --- !u!222 &3289613503060357165
 CanvasRenderer:
@@ -277,7 +277,7 @@ MonoBehaviour:
       m_Calls: []
   m_Sprite: {fileID: 0}
   m_Type: 0
-  m_PreserveAspect: 0
+  m_PreserveAspect: 1
   m_FillCenter: 1
   m_FillMethod: 4
   m_FillAmount: 1
@@ -285,15 +285,15 @@ MonoBehaviour:
   m_FillOrigin: 0
   m_UseSpriteMesh: 0
   m_PixelsPerUnitMultiplier: 1
-  _icon_name: icon_eq_3_4_3
+  _icon_name: icon_GradeBadge_Master
   isNotLoadDeftIcon: 1
-  CurrSpriteAtlas: {fileID: 100100200, guid: 1ef03ad075d5c504196a7354786d23e8, type: 3}
+  CurrSpriteAtlas: {fileID: 100100200, guid: 77f77eea85838ad4b8734050364b4892, type: 3}
   packInfo:
-    packName: allIcon
-    packgJsonPath: /Art/UIAssets/TextrueJson/allIcon.txt
-    packgSpritePath: Assets/Res/UIAtlas/allIcon.spriteatlasv2
-    lasetJsonGUID: 4b54a953fcd0950cece7d4eeea1f40a9
-  imageH: 0
+    packName: daoju
+    packgJsonPath: /Art/UIAssets/TextrueJson\daoju.txt
+    packgSpritePath: Assets/Res/UIAtlas/daoju.spriteatlasv2
+    lasetJsonGUID: 5065c0aff242263ba988030a4cf3800f
+  imageH: 26.404785
   useGradient: 0
   topOrLeftColor: {r: 1, g: 1, b: 1, a: 1}
   bottomOrRightColor: {r: 0, g: 0, b: 0, a: 1}

+ 1 - 1
Assets/Res/UI/ShopPanel/EnergyWidget.prefab

@@ -328,7 +328,7 @@ RectTransform:
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
   m_AnchoredPosition: {x: -66.7, y: 1.2}
-  m_SizeDelta: {x: 34.4441, y: 36.5312}
+  m_SizeDelta: {x: 59.3358, y: 59.3358}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &4099161695515857595
 CanvasRenderer:

+ 1 - 1
Assets/Res/UI/ShopPanel/ShopItemWidgetType1.prefab

@@ -8252,7 +8252,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
   m_AnchoredPosition: {x: 146, y: -23}
-  m_SizeDelta: {x: 182, y: 50}
+  m_SizeDelta: {x: 0, y: 50}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &7048921669090791528
 CanvasRenderer:

+ 13 - 13
Assets/Res/UI/ShopPanel/ShopItemWidgetType2.prefab

@@ -37,7 +37,7 @@ RectTransform:
   m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
   m_AnchorMin: {x: 0, y: 1}
   m_AnchorMax: {x: 0, y: 1}
-  m_AnchoredPosition: {x: 187.50949, y: -43.4515}
+  m_AnchoredPosition: {x: 196.9, y: -43.4515}
   m_SizeDelta: {x: 108, y: 96.45}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &5356034030161481726
@@ -148,7 +148,7 @@ RectTransform:
   m_AnchorMin: {x: 0.5, y: 0.5}
   m_AnchorMax: {x: 0.5, y: 0.5}
   m_AnchoredPosition: {x: 0, y: 39.70005}
-  m_SizeDelta: {x: 165.3682, y: 165.3682}
+  m_SizeDelta: {x: 195.675, y: 195.675}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &3799209826980797111
 CanvasRenderer:
@@ -203,14 +203,14 @@ MonoBehaviour:
   m_FillOrigin: 0
   m_UseSpriteMesh: 0
   m_PixelsPerUnitMultiplier: 1
-  _icon_name: icon_eq_3_2_2
+  _icon_name: icon_Coins_s
   isNotLoadDeftIcon: 0
-  CurrSpriteAtlas: {fileID: 100100200, guid: 1ef03ad075d5c504196a7354786d23e8, type: 3}
+  CurrSpriteAtlas: {fileID: 100100200, guid: 77f77eea85838ad4b8734050364b4892, type: 3}
   packInfo:
-    packName: allIcon
-    packgJsonPath: /Art/UIAssets/TextrueJson/allIcon.txt
-    packgSpritePath: Assets/Res/UIAtlas/allIcon.spriteatlasv2
-    lasetJsonGUID: 4b54a953fcd0950cece7d4eeea1f40a9
+    packName: daoju
+    packgJsonPath: /Art/UIAssets/TextrueJson\daoju.txt
+    packgSpritePath: Assets/Res/UIAtlas/daoju.spriteatlasv2
+    lasetJsonGUID: 5065c0aff242263ba988030a4cf3800f
   imageH: 242.93665
   useGradient: 0
   topOrLeftColor: {r: 1, g: 1, b: 1, a: 1}
@@ -260,7 +260,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 0}
   m_AnchorMax: {x: 0, y: 0}
   m_AnchoredPosition: {x: 0, y: 0}
-  m_SizeDelta: {x: 182, y: 23}
+  m_SizeDelta: {x: 182, y: 232}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!114 &2697255101896436862
 MonoBehaviour:
@@ -565,7 +565,7 @@ RectTransform:
   m_AnchorMin: {x: 0, y: 0}
   m_AnchorMax: {x: 0, y: 0}
   m_AnchoredPosition: {x: 0, y: 0}
-  m_SizeDelta: {x: 82.459, y: 72.493}
+  m_SizeDelta: {x: 101.24, y: 89.007}
   m_Pivot: {x: 0.5, y: 0.5}
 --- !u!222 &6889873714995245063
 CanvasRenderer:
@@ -605,7 +605,7 @@ MonoBehaviour:
   m_FillOrigin: 0
   m_UseSpriteMesh: 0
   m_PixelsPerUnitMultiplier: 1
-  _icon_name: icon_Coins_s
+  _icon_name: icon_Coin
   isNotLoadDeftIcon: 0
   CurrSpriteAtlas: {fileID: 100100200, guid: 77f77eea85838ad4b8734050364b4892, type: 3}
   packInfo:
@@ -1065,14 +1065,14 @@ MonoBehaviour:
   m_FillOrigin: 0
   m_UseSpriteMesh: 0
   m_PixelsPerUnitMultiplier: 1
-  _icon_name: dec_wupin_pinzhi3
+  _icon_name: dec_wupin_pinzhi2
   isNotLoadDeftIcon: 0
   CurrSpriteAtlas: {fileID: 100100200, guid: b02f6b41a7a9fa8458f4226ab6b3ea47, type: 3}
   packInfo:
     packName: tongyong
     packgJsonPath: /Art/UIAssets/TextrueJson\tongyong.txt
     packgSpritePath: Assets/Res/UIAtlas/tongyong.spriteatlasv2
-    lasetJsonGUID: 2de7eb5f66bc0913b66c9fc278c8ba90
+    lasetJsonGUID: 9cac66ffa5050edb28f072b7aefe4150
   imageH: 242.93665
   useGradient: 0
   topOrLeftColor: {r: 1, g: 1, b: 1, a: 1}

+ 43 - 43
Assets/Scenes/testCombat.scene

@@ -2755,7 +2755,7 @@ PrefabInstance:
       objectReference: {fileID: 0}
     - target: {fileID: 9214784224709271120, guid: 1076536f8fdf47942aa287592c6a8b19, type: 3}
       propertyPath: m_IsActive
-      value: 1
+      value: 0
       objectReference: {fileID: 0}
     m_RemovedComponents: []
     m_RemovedGameObjects: []
@@ -4460,7 +4460,7 @@ Sprite:
     3fb1e3f2ace104b39a8b5a61d145264f: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3fb1e3f2ace104b39a8b5a61d145264f, type: 3}
@@ -4554,7 +4554,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -4634,14 +4634,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 272
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 272, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 336, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -5868,7 +5868,7 @@ Sprite:
     3fb1e3f2ace104b39a8b5a61d145264f: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3fb1e3f2ace104b39a8b5a61d145264f, type: 3}
@@ -5962,7 +5962,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -6042,14 +6042,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 272
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 272, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 336, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -11762,7 +11762,7 @@ Sprite:
     3fb1e3f2ace104b39a8b5a61d145264f: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3fb1e3f2ace104b39a8b5a61d145264f, type: 3}
@@ -11856,7 +11856,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -11936,14 +11936,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 272
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 272, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 336, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -12802,7 +12802,7 @@ Sprite:
     3fb1e3f2ace104b39a8b5a61d145264f: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3fb1e3f2ace104b39a8b5a61d145264f, type: 3}
@@ -12896,7 +12896,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -12976,14 +12976,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 272
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 272, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 336, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -14835,7 +14835,7 @@ Sprite:
     3b5496225424c894180fe06fe939122a: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3b5496225424c894180fe06fe939122a, type: 3}
@@ -14929,7 +14929,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -15009,14 +15009,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 136
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 136, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 200, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -15174,7 +15174,7 @@ Sprite:
     3b5496225424c894180fe06fe939122a: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3b5496225424c894180fe06fe939122a, type: 3}
@@ -15268,7 +15268,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -15348,14 +15348,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 136
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 136, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 200, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}
@@ -15486,7 +15486,7 @@ Sprite:
     3fb1e3f2ace104b39a8b5a61d145264f: 21300000
   m_AtlasTags:
   - skillIcon
-  m_SpriteAtlas: {fileID: 100100200, guid: df05f928400d848c387e627e40486378, type: 3}
+  m_SpriteAtlas: {fileID: 0}
   m_RD:
     serializedVersion: 3
     texture: {fileID: 2800000, guid: 3fb1e3f2ace104b39a8b5a61d145264f, type: 3}
@@ -15580,7 +15580,7 @@ Sprite:
     downscaleMultiplier: 1
   m_AtlasRD:
     serializedVersion: 3
-    texture: {fileID: 8711939763936270973, guid: df05f928400d848c387e627e40486378, type: 3}
+    texture: {fileID: 0}
     alphaTexture: {fileID: 0}
     secondaryTextures: []
     m_SubMeshes:
@@ -15660,14 +15660,14 @@ Sprite:
     m_Bindpose: []
     textureRect:
       serializedVersion: 2
-      x: 272
+      x: 0
       y: 0
       width: 128
       height: 128
     textureRectOffset: {x: 0, y: 0}
-    atlasRectOffset: {x: 272, y: 0}
-    settingsRaw: 67
-    uvTransform: {x: 100, y: 336, z: 100, w: 64}
+    atlasRectOffset: {x: -1, y: -1}
+    settingsRaw: 64
+    uvTransform: {x: 100, y: 64, z: 100, w: 64}
     downscaleMultiplier: 1
   m_PhysicsShape:
   - - {x: -0.64, y: 0.64}

+ 77 - 9
Assets/Scripts/GameUI/UI/ItemDetailsPanel/ItemDetailsPanel.cs

@@ -1,6 +1,8 @@
 using System.Collections.Generic;
 using Core.Language;
+using Excel2Json;
 using Fort23.Core;
+using Fort23.UTool;
 using GameLogic.Bag;
 using Utility;
 
@@ -32,34 +34,99 @@ namespace Fort23.Mono
         public async override CTask<bool> AsyncInit(object[] uiData)
         {
             itemInfo = uiData[0] as ItemInfo;
-            Icon_ItemIcon.icon_name = itemInfo.config.icon;
+
             Text_Name.text = LanguageManager.Instance.Text(itemInfo.config.itemName);
             Text_Desc.text = LanguageManager.Instance.Text(itemInfo.config.itemDesc2);
-            Icon_Quality.icon_name  = "dec_wupin_pinzhi" + itemInfo.config.quality;
+            Icon_Quality.icon_name = "dec_wupin_pinzhi" + itemInfo.config.quality;
+
+
+            if (itemInfo.config.associateID == 3)
+            {
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(itemInfo.config.associateVlaue[1] * 10 + 1);
+                if (skillConfig.attribute == 1)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_jin";
+                }
+                else if (skillConfig.attribute == 4)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_mu";
+                }
+                else if (skillConfig.attribute == 2)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_shui";
+                }
+                else if (skillConfig.attribute == 8)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_huo";
+                }
+                else if (skillConfig.attribute == 16)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_tu";
+                }
+            }
+            //碎片
+            else if (itemInfo.config.associateID == 11)
+            {
+                ItemConfig itemConfig2 = ConfigComponent.Instance.Get<ItemConfig>(itemInfo.config.associateVlaue[0]);
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(itemConfig2.associateVlaue[1] * 10 + 1);
+                if (skillConfig.attribute == 1)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_jin";
+                }
+                else if (skillConfig.attribute == 4)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_mu";
+                }
+                else if (skillConfig.attribute == 2)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_shui";
+                }
+                else if (skillConfig.attribute == 8)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_huo";
+                }
+                else if (skillConfig.attribute == 16)
+                {
+                    Icon_ItemIcon.icon_name = "dec_ck_gf_tu";
+                }
+            }
+            else
+            {
+                Icon_ItemIcon.icon_name = itemInfo.config.icon;
+            }
+
 
-            ItemDetailsWidget itemDetailsWidget1 = await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
+            ItemDetailsWidget itemDetailsWidget1 =
+                await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
             itemDetailsWidget1.CustomInit("用途", LanguageManager.Instance.Text(itemInfo.config.itemDesc));
             itemDetailsWidgets.Add(itemDetailsWidget1);
 
             //突破丹
             if (itemInfo.config.associateID == 1)
             {
-                ItemDetailsWidget itemDetailsWidge2 = await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
-                itemDetailsWidge2.CustomInit("服用效果", $"增加成功概率{itemInfo.config.associateVlaue[2]},突破失败降低修为损耗{itemInfo.config.associateVlaue[3]}%");
+                ItemDetailsWidget itemDetailsWidge2 =
+                    await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
+                itemDetailsWidge2.CustomInit("服用效果",
+                    $"增加成功概率{itemInfo.config.associateVlaue[2]},突破失败降低修为损耗{itemInfo.config.associateVlaue[3]}%");
                 itemDetailsWidgets.Add(itemDetailsWidge2);
             }
             //修为丹
             else if (itemInfo.config.associateID == 2)
             {
-                ItemDetailsWidget itemDetailsWidge2 = await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
+                ItemDetailsWidget itemDetailsWidge2 =
+                    await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
                 itemDetailsWidge2.CustomInit("服用效果", $"增加修为值{itemInfo.config.associateVlaue[0]}");
                 itemDetailsWidgets.Add(itemDetailsWidge2);
             }
 
             if (PlayerManager.Instance.BagController.GetItemCount(itemInfo.itemID) > 0)
             {
-                ItemDetailsWidget itemDetailsWidget = await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
-                itemDetailsWidget.CustomInit("道具数量", "道具数量:" + PlayerManager.Instance.BagController.GetItemCount(itemInfo.itemID).ToStringEx());
+                ItemDetailsWidget itemDetailsWidget =
+                    await UIManager.Instance.CreateGComponent<ItemDetailsWidget>(null, Connect);
+                itemDetailsWidget.CustomInit("道具数量",
+                    "道具数量:" + PlayerManager.Instance.BagController.GetItemCount(itemInfo.itemID).ToStringEx());
                 itemDetailsWidgets.Add(itemDetailsWidget);
             }
 
@@ -69,7 +136,8 @@ namespace Fort23.Mono
 
         public static async CTask OpenPanel(ItemInfo itemInfo)
         {
-            await UIManager.Instance.LoadAndOpenPanel<ItemDetailsPanel>(null,UILayer.Top, uiData: new object[] { itemInfo },isShowBG:true);
+            await UIManager.Instance.LoadAndOpenPanel<ItemDetailsPanel>(null, UILayer.Top,
+                uiData: new object[] { itemInfo }, isShowBG: true);
         }
 
         public override void Close()

+ 30 - 4
Assets/Scripts/GameUI/UI/RewardsPanel/WidgetItem.cs

@@ -56,7 +56,35 @@ namespace Fort23.Mono
 
             if (itemInfo.config.associateID == 3)
             {
-                SkillConfig skillConfig = ConfigComponent.Instance.Get<SkillConfig>(itemInfo.config.associateVlaue[1]*10+1);
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(itemInfo.config.associateVlaue[1] * 10 + 1);
+                if (skillConfig.attribute == 1)
+                {
+                    icon.icon_name = "dec_ck_gf_jin";
+                }
+                else if (skillConfig.attribute == 4)
+                {
+                    icon.icon_name = "dec_ck_gf_mu";
+                }
+                else if (skillConfig.attribute == 2)
+                {
+                    icon.icon_name = "dec_ck_gf_shui";
+                }
+                else if (skillConfig.attribute == 8)
+                {
+                    icon.icon_name = "dec_ck_gf_huo";
+                }
+                else if (skillConfig.attribute == 16)
+                {
+                    icon.icon_name = "dec_ck_gf_tu";
+                }
+            }
+            //碎片
+            else if (itemInfo.config.associateID == 11)
+            {
+                ItemConfig itemConfig2 = ConfigComponent.Instance.Get<ItemConfig>(itemInfo.config.associateVlaue[0]);
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(itemConfig2.associateVlaue[1] * 10 + 1);
                 if (skillConfig.attribute == 1)
                 {
                     icon.icon_name = "dec_ck_gf_jin";
@@ -77,8 +105,6 @@ namespace Fort23.Mono
                 {
                     icon.icon_name = "dec_ck_gf_tu";
                 }
-                               
-
             }
             else
             {
@@ -86,7 +112,7 @@ namespace Fort23.Mono
             }
 
             icon.gameObject.SetActive(true);
-        
+
             Icon_WenHao.gameObject.SetActive(false);
 
             if (itemInfo.count.Value > 0)

+ 64 - 3
Assets/Scripts/GameUI/UI/ShopPanel/ShopItemWidgetType2.cs

@@ -55,12 +55,16 @@ namespace Fort23.Mono
                 }
                 else
                 {
-                    ShopBuyItemPanel shopBuyItemPanel = await UIManager.Instance.LoadAndOpenPanel<ShopBuyItemPanel>(null, isShowBG: true, layer: UILayer.Top);
+                    ShopBuyItemPanel shopBuyItemPanel =
+                        await UIManager.Instance.LoadAndOpenPanel<ShopBuyItemPanel>(null, isShowBG: true,
+                            layer: UILayer.Top);
                     shopBuyItemPanel.CustomInit(_shopItem, async (b, count) =>
                     {
                         if (b)
                         {
-                            if (_shopItemConfig.price != 0 && !PlayerManager.Instance.BagController.IsEnough(_shopItemConfig.costItemId, _shopItemConfig.price * count))
+                            if (_shopItemConfig.price != 0 &&
+                                !PlayerManager.Instance.BagController.IsEnough(_shopItemConfig.costItemId,
+                                    _shopItemConfig.price * count))
                             {
                                 TipMessagePanel.OpenTipMessagePanel(829, Vector2.zero);
                                 return;
@@ -161,7 +165,64 @@ namespace Fort23.Mono
             LayoutRebuilder.ForceRebuildLayoutImmediate(Group_Price.GetComponent<RectTransform>());
 
             Icon_PriceItem.icon_name = itemConfig.icon;
-            Icon_Item.icon_name = _shopItemConfig.shopShowTemplateParm[0];
+
+
+            if (_itemConfig.associateID == 3)
+            {
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(_itemConfig.associateVlaue[1] * 10 + 1);
+                if (skillConfig.attribute == 1)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_jin";
+                }
+                else if (skillConfig.attribute == 4)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_mu";
+                }
+                else if (skillConfig.attribute == 2)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_shui";
+                }
+                else if (skillConfig.attribute == 8)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_huo";
+                }
+                else if (skillConfig.attribute == 16)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_tu";
+                }
+            }
+            //碎片
+            else if (_itemConfig.associateID == 11)
+            {
+                ItemConfig itemConfig2 = ConfigComponent.Instance.Get<ItemConfig>(_itemConfig.associateVlaue[0]);
+                SkillConfig skillConfig =
+                    ConfigComponent.Instance.Get<SkillConfig>(itemConfig2.associateVlaue[1] * 10 + 1);
+                if (skillConfig.attribute == 1)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_jin";
+                }
+                else if (skillConfig.attribute == 4)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_mu";
+                }
+                else if (skillConfig.attribute == 2)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_shui";
+                }
+                else if (skillConfig.attribute == 8)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_huo";
+                }
+                else if (skillConfig.attribute == 16)
+                {
+                    Icon_Item.icon_name = "dec_ck_gf_tu";
+                }
+            }
+            else
+            {
+                Icon_Item.icon_name =_itemConfig.icon;
+            }
 
             Text_Name.text = LanguageManager.Instance.Text(_itemConfig.itemName);
             Text_Num.text = _shopItemConfig.itemCount[0].ToString();