using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; //============================================================ //支持中文,文件使用UTF-8编码 //@author YangHua //@create 20230913 //@company Adam // //@description: //============================================================ namespace Adam { public class AssignmentController : MonoBehaviour { public GameObject RWPanel; public RectTransform rws; public Button loadBtn; public Vector2 originPos = new Vector2(); private void Start() { originPos = rws.anchoredPosition; loadBtn.onClick.AddListener(OnLoad); SwitchPanel(false); } public void SwitchPanel(bool isActive) { RWPanel.SetActive(isActive); } public void ChangeRWPanelPos() { rws.anchoredPosition = originPos; } public void OnLoad() { UIManager.Instance.bottomCotroller.SwitchPanel(true); UIManager.Instance.exitBtn.gameObject.SetActive(true); rws.anchoredPosition = Vector2.zero; loadBtn.gameObject.SetActive(false); SwitchPanel(false); SceneLoad.Instance.SceneChange("工具间场景"); } } }