28 lines
869 B
C#
28 lines
869 B
C#
using System.Collections.Generic;
|
|
using TMPro;
|
|
using UnityEngine;
|
|
|
|
public class MainStatCardBase : MonoBehaviour
|
|
{
|
|
public static List<eStat> list_stat = new List<eStat>
|
|
{
|
|
eStat.Max, eStat.Cri, eStat.CriDmg, eStat.HitRate,
|
|
eStat.MaxHP, eStat.MaxShield, eStat.Avoid_Melee, eStat.Avoid_Range
|
|
};
|
|
|
|
public TextMeshProUGUI[] texts; // 0 스탯, 1 스탯값
|
|
|
|
public void Set(eStat stat, ActorStatInfo statinfo)
|
|
{
|
|
if (stat == eStat.Max)
|
|
{
|
|
texts[0].text = table_localtext.Ins.Get_Text(4000);
|
|
texts[1].text = $"{statinfo.Get_TotalStat(eStat.Attack_Min)}~{statinfo.Get_TotalStat(eStat.Attack_Max)}";
|
|
}
|
|
else
|
|
{
|
|
texts[0].text = MyText.Get_StatName(stat);
|
|
texts[1].text = MyText.Get_StatValueText(stat, statinfo.Get_TotalStat(stat), true);
|
|
}
|
|
}
|
|
} |