Main.tscn 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235
  1. [gd_scene load_steps=18 format=2]
  2. [ext_resource path="res://scripts/Platform.gd" type="Script" id=1]
  3. [ext_resource path="res://scripts/ball.gd" type="Script" id=2]
  4. [ext_resource path="res://scripts/Hummer.gd" type="Script" id=3]
  5. [ext_resource path="res://scripts/Label_With_Font.gd" type="Script" id=4]
  6. [ext_resource path="res://sounds/ping.ogg" type="AudioStream" id=5]
  7. [ext_resource path="res://sounds/pong.ogg" type="AudioStream" id=6]
  8. [ext_resource path="res://sounds/pam.ogg" type="AudioStream" id=7]
  9. [ext_resource path="res://sounds/nyo.ogg" type="AudioStream" id=8]
  10. [ext_resource path="res://scripts/NYA.gd" type="Script" id=9]
  11. [ext_resource path="res://sounds/nya.ogg" type="AudioStream" id=10]
  12. [ext_resource path="res://scripts/Main.gd" type="Script" id=11]
  13. [ext_resource path="res://scripts/HiScore.gd" type="Script" id=12]
  14. [ext_resource path="res://sounds/goodboy.ogg" type="AudioStream" id=13]
  15. [ext_resource path="res://scripts/REWARD_LABEL.gd" type="Script" id=14]
  16. [ext_resource path="res://scripts/START_LABEL.gd" type="Script" id=15]
  17. [ext_resource path="res://scripts/ScoreLabel.gd" type="Script" id=16]
  18. [sub_resource type="AudioStreamGenerator" id=1]
  19. [node name="MAIN" type="Node2D"]
  20. script = ExtResource( 11 )
  21. [node name="HiScore" type="Label" parent="."]
  22. margin_left = 403.0
  23. margin_top = 177.0
  24. margin_right = 443.0
  25. margin_bottom = 208.0
  26. text = "Score
  27. "
  28. script = ExtResource( 12 )
  29. __meta__ = {
  30. "_edit_use_anchors_": false
  31. }
  32. [node name="REWARD_LABEL" type="Label" parent="."]
  33. margin_left = 37.0
  34. margin_top = 508.0
  35. margin_right = 92.0
  36. margin_bottom = 539.0
  37. text = "REWARD"
  38. script = ExtResource( 14 )
  39. __meta__ = {
  40. "_edit_use_anchors_": false
  41. }
  42. [node name="ScoreLabel" type="Label" parent="."]
  43. margin_left = 368.0
  44. margin_top = 230.0
  45. margin_right = 408.0
  46. margin_bottom = 261.0
  47. text = "Score
  48. "
  49. script = ExtResource( 16 )
  50. __meta__ = {
  51. "_edit_use_anchors_": false
  52. }
  53. [node name="START_LABEL" type="Label" parent="."]
  54. margin_left = 368.0
  55. margin_top = 230.0
  56. margin_right = 408.0
  57. margin_bottom = 261.0
  58. text = "PRESS SPACE TO START
  59. "
  60. script = ExtResource( 15 )
  61. font_size = 23
  62. [node name="instructions_1" type="Label" parent="."]
  63. margin_left = 28.0
  64. margin_top = 15.0
  65. margin_right = 412.0
  66. margin_bottom = 97.0
  67. text = "2 Platforms. P1 and P2
  68. P1 is higher pitch and is controlled with left and right arrows
  69. (try it now)
  70. P2 is lower pitch and is controlled with A and D
  71. P1 says \"ping\" when hit
  72. P2 says \"pong\"
  73. P1 says \"nya\" when miss
  74. P2 says \"nyo\""
  75. script = ExtResource( 4 )
  76. __meta__ = {
  77. "_edit_use_anchors_": false
  78. }
  79. [node name="instructions_2" type="Label" parent="."]
  80. margin_left = 635.0
  81. margin_top = 217.0
  82. margin_right = 1019.0
  83. margin_bottom = 316.0
  84. text = "The ball is high pulsing sound.
  85. It is pulsing fast when going towards P2
  86. and slower when it goes towards P1
  87. It becomes louder as it gets closer to P2 side.
  88. It is stationary unless you start the game."
  89. script = ExtResource( 4 )
  90. __meta__ = {
  91. "_edit_use_anchors_": false
  92. }
  93. [node name="instructions_3" type="Label" parent="."]
  94. margin_left = 279.0
  95. margin_top = 422.0
  96. margin_right = 663.0
  97. margin_bottom = 521.0
  98. text = "You get the score when you hit any of 2 platforms.
  99. You lose when you miss."
  100. script = ExtResource( 4 )
  101. __meta__ = {
  102. "_edit_use_anchors_": false
  103. }
  104. font_size = 21
  105. [node name="instructions_4" type="Label" parent="."]
  106. margin_left = 547.0
  107. margin_top = 38.0
  108. margin_right = 931.0
  109. margin_bottom = 137.0
  110. text = "Hodge podge text layout is ugly!
  111. Close your eyes to not see it anymore."
  112. script = ExtResource( 4 )
  113. __meta__ = {
  114. "_edit_use_anchors_": false
  115. }
  116. font_size = 21
  117. [node name="instructions_5" type="Label" parent="."]
  118. margin_left = 22.0
  119. margin_top = 367.0
  120. margin_right = 406.0
  121. margin_bottom = 466.0
  122. text = "wear headphones the right way!!!"
  123. script = ExtResource( 4 )
  124. __meta__ = {
  125. "_edit_use_anchors_": false
  126. }
  127. font_size = 23
  128. [node name="PLATFORM1" type="ColorRect" parent="."]
  129. visible = false
  130. margin_right = 250.0
  131. margin_bottom = 40.0
  132. script = ExtResource( 1 )
  133. __meta__ = {
  134. "_edit_use_anchors_": false
  135. }
  136. [node name="Hummer1" type="AudioStreamPlayer2D" parent="PLATFORM1"]
  137. position = Vector2( 125, 18 )
  138. stream = SubResource( 1 )
  139. volume_db = -4.0
  140. script = ExtResource( 3 )
  141. pulse_hz = 220.0
  142. [node name="PING" type="AudioStreamPlayer2D" parent="PLATFORM1"]
  143. position = Vector2( 125, 18 )
  144. stream = ExtResource( 5 )
  145. [node name="PLATFORM2" type="ColorRect" parent="."]
  146. visible = false
  147. margin_top = 560.0
  148. margin_right = 250.0
  149. margin_bottom = 600.0
  150. script = ExtResource( 1 )
  151. __meta__ = {
  152. "_edit_use_anchors_": false
  153. }
  154. right_action = "right2"
  155. left_action = "left2"
  156. [node name="Hummer2" type="AudioStreamPlayer2D" parent="PLATFORM2"]
  157. position = Vector2( 127, 19 )
  158. stream = SubResource( 1 )
  159. volume_db = -4.0
  160. script = ExtResource( 3 )
  161. pulse_hz = 110.0
  162. [node name="PING" type="AudioStreamPlayer2D" parent="PLATFORM2"]
  163. position = Vector2( 127, 19 )
  164. stream = ExtResource( 6 )
  165. volume_db = 5.0
  166. [node name="ball" type="ColorRect" parent="."]
  167. visible = false
  168. margin_top = 320.0
  169. margin_right = 40.0
  170. margin_bottom = 360.0
  171. script = ExtResource( 2 )
  172. __meta__ = {
  173. "_edit_use_anchors_": false
  174. }
  175. [node name="Hummer3" type="AudioStreamPlayer2D" parent="ball"]
  176. position = Vector2( 127, 259 )
  177. stream = SubResource( 1 )
  178. volume_db = -8.0
  179. attenuation = 0.0441942
  180. bus = "ball"
  181. script = ExtResource( 3 )
  182. pulse_hz = 1760.0
  183. [node name="PAM" type="AudioStreamPlayer2D" parent="ball"]
  184. position = Vector2( 127, 259 )
  185. stream = ExtResource( 7 )
  186. volume_db = 8.0
  187. attenuation = 0.00497875
  188. bus = "ball"
  189. [node name="NYA" type="Node2D" parent="."]
  190. script = ExtResource( 9 )
  191. [node name="NYA" type="AudioStreamPlayer2D" parent="NYA"]
  192. stream = ExtResource( 10 )
  193. attenuation = 0.0490366
  194. [node name="NYO" type="AudioStreamPlayer2D" parent="NYA"]
  195. stream = ExtResource( 8 )
  196. attenuation = 0.0490366
  197. [node name="BLACK_WEIL" type="Polygon2D" parent="."]
  198. z_index = -1
  199. color = Color( 0, 0, 0, 1 )
  200. polygon = PoolVector2Array( 170.181, -70.1721, -129.819, 13.8279, -129.819, 286.828, -82.819, 475.828, 15.181, 709.538, 1054.54, 649.538, 1037.54, -44.6059 )
  201. [node name="SOUND_REWARD" type="AudioStreamPlayer2D" parent="."]
  202. position = Vector2( 496, 290 )
  203. stream = ExtResource( 13 )
  204. volume_db = 12.0