PolygonSceneSelect.cs 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4. using UnityEngine.SceneManagement;
  5. using UnityEngine.UI;
  6. using UnityEngine.Events;
  7. namespace PolygonArsenal
  8. {
  9. public class PolygonSceneSelect : MonoBehaviour
  10. {
  11. public bool GUIHide = false;
  12. public bool GUIHide2 = false;
  13. public bool GUIHide3 = false;
  14. public void LoadSceneDemoMissiles()
  15. {
  16. SceneManager.LoadScene("PolygonDemoMissiles");
  17. }
  18. public void LoadSceneDemoBeams()
  19. {
  20. SceneManager.LoadScene("PolygonDemoBeams");
  21. }
  22. public void LoadSceneDemo01()
  23. {
  24. SceneManager.LoadScene("PolygonDemo01");
  25. }
  26. public void LoadSceneDemo02()
  27. {
  28. SceneManager.LoadScene("PolygonDemo02");
  29. }
  30. public void LoadSceneDemo03()
  31. {
  32. SceneManager.LoadScene("PolygonDemo03");
  33. }
  34. public void LoadSceneDemo04()
  35. {
  36. SceneManager.LoadScene("PolygonDemo04");
  37. }
  38. public void LoadSceneDemo05()
  39. {
  40. SceneManager.LoadScene("PolygonDemo05");
  41. }
  42. public void LoadSceneDemo06()
  43. {
  44. SceneManager.LoadScene("PolygonDemo06");
  45. }
  46. public void LoadSceneDemo07()
  47. {
  48. SceneManager.LoadScene("PolygonDemo07");
  49. }
  50. public void LoadSceneDemo08()
  51. {
  52. SceneManager.LoadScene("PolygonDemo08");
  53. }
  54. public void LoadSceneDemo09()
  55. {
  56. SceneManager.LoadScene("PolygonDemo09");
  57. }
  58. public void LoadSceneDemo10()
  59. {
  60. SceneManager.LoadScene("PolygonDemo10");
  61. }
  62. public void LoadSceneDemo11()
  63. {
  64. SceneManager.LoadScene("PolygonDemo11");
  65. }
  66. public void LoadSceneDemo12()
  67. {
  68. SceneManager.LoadScene("PolygonDemo12");
  69. }
  70. public void LoadSceneDemo13()
  71. {
  72. SceneManager.LoadScene("PolygonDemo13");
  73. }
  74. public void LoadSceneDemo14()
  75. {
  76. SceneManager.LoadScene("PolygonDemo14");
  77. }
  78. public void LoadSceneDemo15()
  79. {
  80. SceneManager.LoadScene("PolygonDemo15");
  81. }
  82. public void LoadSceneDemo16()
  83. {
  84. SceneManager.LoadScene("PolygonDemo16");
  85. }
  86. public void LoadSceneDemo17()
  87. {
  88. SceneManager.LoadScene("PolygonDemo17");
  89. }
  90. public void LoadSceneDemo18()
  91. {
  92. SceneManager.LoadScene("PolygonDemo18");
  93. }
  94. public void LoadSceneDemo19()
  95. {
  96. SceneManager.LoadScene("PolygonDemo19");
  97. }
  98. public void LoadSceneDemo20()
  99. {
  100. SceneManager.LoadScene("PolygonDemo20");
  101. }
  102. public void LoadSceneDemo21()
  103. {
  104. SceneManager.LoadScene("PolygonDemo21");
  105. }
  106. public void LoadSceneDemo22()
  107. {
  108. SceneManager.LoadScene("PolygonDemo22");
  109. }
  110. public void LoadSceneDemo23()
  111. {
  112. SceneManager.LoadScene("PolygonDemo23");
  113. }
  114. void Update ()
  115. {
  116. if(Input.GetKeyDown(KeyCode.L))
  117. {
  118. GUIHide = !GUIHide;
  119. if (GUIHide)
  120. {
  121. GameObject.Find("CanvasSceneSelect").GetComponent<Canvas> ().enabled = false;
  122. }
  123. else
  124. {
  125. GameObject.Find("CanvasSceneSelect").GetComponent<Canvas> ().enabled = true;
  126. }
  127. }
  128. if(Input.GetKeyDown(KeyCode.J))
  129. {
  130. GUIHide2 = !GUIHide2;
  131. if (GUIHide2)
  132. {
  133. GameObject.Find("CanvasMissiles").GetComponent<Canvas> ().enabled = false;
  134. }
  135. else
  136. {
  137. GameObject.Find("CanvasMissiles").GetComponent<Canvas> ().enabled = true;
  138. }
  139. }
  140. if(Input.GetKeyDown(KeyCode.H))
  141. {
  142. GUIHide3 = !GUIHide3;
  143. if (GUIHide3)
  144. {
  145. GameObject.Find("CanvasTips").GetComponent<Canvas> ().enabled = false;
  146. }
  147. else
  148. {
  149. GameObject.Find("CanvasTips").GetComponent<Canvas> ().enabled = true;
  150. }
  151. }
  152. }
  153. }
  154. }