using System.Collections.Generic; using UnityEngine; public class ChooseManage : MonoBehaviour { public List openlist; public List closelist; private void Start() { } public void changeList(int index) { for (int i = 0; i < openlist.Count; i++) { openlist[i].SetActive(false); closelist[i].SetActive(true); } openlist[index].SetActive(true); } }