LayoutManager.cs 587 B

12345678910111213141516171819202122232425262728293031
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. public class LayoutManager : MonoBehaviour
  5. {
  6. public GameObject layout2;
  7. void Start()
  8. {
  9. }
  10. // Update is called once per frame
  11. void Update()
  12. {
  13. if (GlobalData.MyDeviceMode == DeviceMode.Gun)
  14. {
  15. if (layout2.activeSelf)
  16. {
  17. layout2.SetActive(false);
  18. }
  19. }
  20. else
  21. {
  22. if (!layout2.activeSelf)
  23. {
  24. layout2.SetActive(true);
  25. }
  26. }
  27. }
  28. }