- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- public class Temp3D : MonoBehaviour
- {
- public GameObject[] layer;
- public void ChangeLayer(int index) {
- for (int i = 0; i < layer.Length; i++) {
- layer[i].gameObject.SetActive(false);
- }
- layer[index].gameObject.SetActive(true);
- }
- }
|