_TheStrongestSnail/TheStrongestSnail/Assets/Scripts/ListBtn.cs
2024-11-23 21:47:04 +08:00

24 lines
417 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class ListBtn : MonoBehaviour
{
public Button btn;
// Start is called before the first frame update
void Start()
{
btn=GetComponent<Button>();
btn.onClick.AddListener(OnClickBtn);
}
public void OnClickBtn()
{
ListPanel.instance.ShowPanel();
}
}