forked from TTalvenH/Myyra
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Main.tscn
97 lines (78 loc) · 2.9 KB
/
Main.tscn
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
[gd_scene load_steps=8 format=2]
[ext_resource path="res://roots.tscn" type="PackedScene" id=1]
[ext_resource path="res://Player.tscn" type="PackedScene" id=2]
[ext_resource path="res://MobSpawn.gd" type="Script" id=3]
[ext_resource path="res://myyrahorrorcore.ogg" type="AudioStream" id=4]
[ext_resource path="res://bg.tscn" type="PackedScene" id=5]
[ext_resource path="res://PauseScreen.tscn" type="PackedScene" id=6]
[ext_resource path="res://HUD.gd" type="Script" id=7]
[node name="Main" type="Node2D"]
[node name="BG" parent="." instance=ExtResource( 5 )]
[node name="RootSpawn" parent="." instance=ExtResource( 1 )]
[node name="MobSpawn" type="Node2D" parent="."]
script = ExtResource( 3 )
[node name="Mobtimer" type="Timer" parent="MobSpawn"]
autostart = true
[node name="Player" parent="." instance=ExtResource( 2 )]
position = Vector2( 343, 4 )
air_friction = 0.008
[node name="AudioStreamPlayer2D" type="AudioStreamPlayer2D" parent="."]
stream = ExtResource( 4 )
autoplay = true
[node name="PauseScreen" parent="." instance=ExtResource( 6 )]
visible = false
margin_right = 25.0
margin_bottom = 18.0
[node name="HUD" type="CanvasLayer" parent="."]
script = ExtResource( 7 )
[node name="ScoreLabel" type="Label" parent="HUD"]
margin_left = 8.0
margin_top = 8.0
margin_right = 80.0
margin_bottom = 24.0
text = "0"
[node name="Message" type="Label" parent="HUD"]
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
margin_top = -116.0
margin_bottom = -84.0
text = "Slide on roots and dodge the angry roots!"
align = 1
[node name="ScoreTimer" type="Timer" parent="HUD"]
[node name="MessageTimer" type="Timer" parent="HUD"]
wait_time = 3.0
[node name="GameOverLabel" type="Label" parent="HUD"]
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
margin_top = -7.0
margin_bottom = 7.0
text = "Game Over"
align = 1
[node name="RestartButton" type="Button" parent="HUD"]
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
margin_left = 288.0
margin_top = 20.0
margin_right = -288.0
margin_bottom = 40.0
text = "Restart"
[node name="QuitButton" type="Button" parent="HUD"]
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
margin_left = 288.0
margin_top = 47.0
margin_right = -288.0
margin_bottom = 67.0
text = "Quit"
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="HUD"]
[connection signal="timeout" from="MobSpawn/Mobtimer" to="MobSpawn" method="_on_Mobtimer_timeout"]
[connection signal="game_over" from="Player" to="HUD" method="game_over"]
[connection signal="paused" from="Player" to="PauseScreen" method="_on_Player_paused"]
[connection signal="timeout" from="HUD/ScoreTimer" to="HUD" method="_on_ScoreTimer_timeout"]
[connection signal="timeout" from="HUD/MessageTimer" to="HUD" method="_on_MessageTimer_timeout"]
[connection signal="pressed" from="HUD/RestartButton" to="HUD" method="_on_RestartButton_pressed"]
[connection signal="pressed" from="HUD/QuitButton" to="HUD" method="_on_QuitButton_pressed"]