diff --git a/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Buttons/Skill Button.prefab b/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Buttons/Skill Button.prefab index e305869c..0e8f7d71 100644 --- a/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Buttons/Skill Button.prefab +++ b/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Buttons/Skill Button.prefab @@ -173,7 +173,7 @@ MonoBehaviour: m_enableAutoSizing: 0 m_fontSizeMin: 18 m_fontSizeMax: 72 - m_fontStyle: 0 + m_fontStyle: 1 m_HorizontalAlignment: 2 m_VerticalAlignment: 512 m_textAlignment: 65535 @@ -268,7 +268,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 1, g: 0.4669811, b: 0.4669811, a: 1} + m_Color: {r: 0.1792453, g: 0.1792453, b: 0.1792453, a: 0.78039217} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 @@ -331,10 +331,10 @@ RectTransform: m_Children: [] m_Father: {fileID: 3622686016877026920} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0, y: 0.5} - m_AnchorMax: {x: 1, y: 0.5} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: -80, y: 50} + m_SizeDelta: {x: -80, y: -80} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &8744157009323514992 CanvasRenderer: @@ -364,7 +364,7 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Sprite: {fileID: 0} + m_Sprite: {fileID: 21300000, guid: 5b4b413a992e84746ae4f88cfa896976, type: 3} m_Type: 0 m_PreserveAspect: 0 m_FillCenter: 1 @@ -569,37 +569,20 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 35c94c75c6e511048b4a77d3682e1f85, type: 3} m_Name: m_EditorClassIdentifier: - skillData: - id: - name: - mpConsumption: 0 - damage: 0 - coolDown: 0 - slotNumber: 0 - requiredLevel: 0 coolTimeText: {fileID: 1353060829719948495} coolTimeDimd: {fileID: 561526979871276618} skillIcon: {fileID: 4450630482936255251} lockImage: {fileID: 9104780789004064627} - skillSprite: - keys: - - K0001 - - K0002 - - K0003 - - K0004 - - K0005 - - K0006 - - K0007 - - K0008 - values: - - Value: {fileID: 21300000, guid: 0c6802c457ef3a049babd141698d0763, type: 3} - - Value: {fileID: 21300000, guid: dbd065e74e8e2f840a037a91d8ac8b08, type: 3} - - Value: {fileID: 0} - - Value: {fileID: 0} - - Value: {fileID: 0} - - Value: {fileID: 0} - - Value: {fileID: 21300000, guid: 373fbf69075cebf46992176be6e81b0e, type: 3} - - Value: {fileID: 0} + skillBase: + k__BackingField: + id: + name: + mpConsumption: 0 + damage: 0 + coolDown: 0 + slotNumber: 0 + requiredLevel: 0 + k__BackingField: 0 --- !u!1 &9104780789004064627 GameObject: m_ObjectHideFlags: 0 diff --git a/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Skill Item/Skill Information Item.prefab b/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Skill Item/Skill Information Item.prefab index 08461aa9..9f4b829b 100644 --- a/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Skill Item/Skill Information Item.prefab +++ b/Gameton-06/Assets/Gameton/Resources/UI/Prefabs/Skill Item/Skill Information Item.prefab @@ -339,6 +339,7 @@ RectTransform: - {fileID: 3675381532938835687} - {fileID: 4120547496715140997} - {fileID: 4304049488470214548} + - {fileID: 606335664229192302} m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 1} @@ -399,7 +400,7 @@ MonoBehaviour: imageSprites: keys: [] values: [] - skillImage: {fileID: 1387251271655878441} + skillImage: {fileID: 8663022219627117037} skillName: {fileID: 8742526129269004090} skillDamage: {fileID: 6604346907373336785} skillCooltime: {fileID: 5644015466645616352} @@ -480,6 +481,81 @@ RectTransform: m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} +--- !u!1 &4700205265606634099 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 4299713573730494146} + - component: {fileID: 3502525450604665862} + - component: {fileID: 3913839814436982144} + m_Layer: 0 + m_Name: Seletecd Image + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &4299713573730494146 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4700205265606634099} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 606335664229192302} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!222 &3502525450604665862 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4700205265606634099} + m_CullTransparentMesh: 1 +--- !u!114 &3913839814436982144 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4700205265606634099} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 2aa08635294c7f4439316a676e949dc8, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 --- !u!1 &4707606874280356476 GameObject: m_ObjectHideFlags: 0 @@ -726,6 +802,42 @@ MonoBehaviour: m_FillOrigin: 0 m_UseSpriteMesh: 0 m_PixelsPerUnitMultiplier: 1 +--- !u!1 &6064772624787250806 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 606335664229192302} + m_Layer: 0 + m_Name: Selected State + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!224 &606335664229192302 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 6064772624787250806} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 1.0529689} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 4299713573730494146} + m_Father: {fileID: 3123293382822292774} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} --- !u!1 &6258453056217813560 GameObject: m_ObjectHideFlags: 0 @@ -1279,7 +1391,7 @@ GameObject: m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 - m_IsActive: 1 + m_IsActive: 0 --- !u!224 &6714506408579064812 RectTransform: m_ObjectHideFlags: 0 @@ -1296,8 +1408,8 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 1} m_AnchorMax: {x: 0.5, y: 1} - m_AnchoredPosition: {x: -0.000015258789, y: 0} - m_SizeDelta: {x: 60, y: 60} + m_AnchoredPosition: {x: 0, y: -10} + m_SizeDelta: {x: 50, y: 50} m_Pivot: {x: 0.5, y: 1} --- !u!222 &6637995555379658870 CanvasRenderer: diff --git a/Gameton-06/Assets/Gameton/Scripts/Skill/SkillInformationItem.cs b/Gameton-06/Assets/Gameton/Scripts/Skill/SkillInformationItem.cs index e5ef04b4..ec764265 100644 --- a/Gameton-06/Assets/Gameton/Scripts/Skill/SkillInformationItem.cs +++ b/Gameton-06/Assets/Gameton/Scripts/Skill/SkillInformationItem.cs @@ -2,6 +2,7 @@ using System.Collections; using System.Collections.Generic; using TMPro; using UnityEngine; +using UnityEngine.Assertions; using UnityEngine.UI; namespace TON @@ -11,7 +12,7 @@ namespace TON [SerializeField] SerializableDictionary imageSprites = new SerializableDictionary(); - public Image skillImage; + public GameObject skillImage; public TextMeshProUGUI skillName; public TextMeshProUGUI skillDamage; public TextMeshProUGUI skillCooltime; @@ -29,6 +30,10 @@ namespace TON skillReqMp.text = $"{skillData.mpConsumption}"; skillReqLv.text = $"{skillData.requiredLevel}"; + Assert.IsTrue(AssetManager.Singleton.LoadSkillIcon(skillData.id, out Sprite loadedSkillImage)); + skillImage.SetActive(true); + skillImage.GetComponent().sprite = loadedSkillImage; + if (playerLevel >= skillData.requiredLevel) { locker.SetActive(false);