using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; //============================================================ //支持中文,文件使用UTF-8编码 //@author YangHua //@create 20230914 //@company QianHuo // //@description: //============================================================ namespace Components { public class PermanentToolItem : MonoBehaviour { public Button selfBtn; public GameObject panel; // Use this for initialization private void Start() { panel.SetActive(false); selfBtn.onClick.AddListener(() => { OnSelf(); }); } public void OnSelf() { UIManager.Instance.ToolsItemManager.SwictchToolPanel(false); panel.SetActive(true); } } }