Project_WL/Assets/Script/UI/PC/PCUI_LvInfo.cs

27 lines
942 B
C#
Raw Permalink Normal View History

2024-12-15 01:39:39 +00:00
using TMPro;
2025-03-13 00:10:58 +00:00
using UnityEngine;
2024-12-15 01:39:39 +00:00
using UnityEngine.UI;
2025-03-13 00:10:58 +00:00
public class PCUI_LvInfo : MonoBehaviour
2024-12-15 01:39:39 +00:00
{
2025-07-16 16:43:31 +00:00
public Image[] images; // 0 전투타입, 1 직업
public TextMeshProUGUI[] texts; // 0 null, 1 레벨, 2 경험치, 3 무기종류
public Slider slider_exp;
2024-12-15 01:39:39 +00:00
private void OnEnable()
{
Set();
}
public void Set()
{
var sdata = ServerInfo.Ins.m_ServerData;
var classData = table_classconfig.Ins.Get_Data_orNull(sdata.Get_EqiupmentEquip(eItem.PC));
2025-08-05 02:48:21 +00:00
images[1].sprite = UIAtlasMgr.Ins.Get_Sprite(classData.s_JobIcon);
2025-07-16 16:43:31 +00:00
//texts[0].text = classData.Get_JobName();
texts[1].text = $"Lv. {sdata.PC.Lv}";
texts[2].text = MyText.Get_PercentValueText_100(sdata.PC.Get_ExpSliderValue());
2025-02-15 00:45:35 +00:00
if (texts.Length > 3) texts[3].text = classData.e_BattleType.ToString();
2025-07-16 16:43:31 +00:00
if (!DSUtil.CheckNull(slider_exp)) slider_exp.value = sdata.PC.Get_ExpSliderValue();
2024-12-15 01:39:39 +00:00
}
}