using UnityEngine; using UnityEngine.UI; namespace Snxxz.UI { public class EquipLvSelect : MonoBehaviour { [SerializeField] Button lvBtn; public PlayerPackModel.EquipLvType lvType; public Text lvText; PlayerPackModel playerPack { get { return ModelCenter.Instance.GetModel(); } } private void OnEnable() { lvBtn.AddListener(ClickLvBtn); } private void OnDisable() { lvBtn.RemoveAllListeners(); } private void ClickLvBtn() { playerPack.SetLvSelect(lvType); } } }