스킬 이미지 연동부분 적용
This commit is contained in:
@@ -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<string, Sprite> imageSprites = new SerializableDictionary<string, Sprite>();
|
||||
|
||||
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<Image>().sprite = loadedSkillImage;
|
||||
|
||||
if (playerLevel >= skillData.requiredLevel)
|
||||
{
|
||||
locker.SetActive(false);
|
||||
|
||||
Reference in New Issue
Block a user