starting to implement twitch
This commit is contained in:
parent
3e6fa5ff78
commit
2cd7af98a1
6 changed files with 28 additions and 3 deletions
15
game.tscn
15
game.tscn
|
|
@ -61,7 +61,7 @@ music_player = NodePath("MusicPlayer")
|
||||||
win_player = NodePath("WinMusic")
|
win_player = NodePath("WinMusic")
|
||||||
flyover_player = NodePath("Flyover")
|
flyover_player = NodePath("Flyover")
|
||||||
intro_player = NodePath("IntroPlayer")
|
intro_player = NodePath("IntroPlayer")
|
||||||
start_button = NodePath("GameUI/Button")
|
start_button = NodePath("GameUI/StartButton")
|
||||||
|
|
||||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||||
texture_filter = 1
|
texture_filter = 1
|
||||||
|
|
@ -319,7 +319,7 @@ text = "Scoreboard"
|
||||||
[node name="scorecard_container" type="VBoxContainer" parent="GameUI/Scoreboard/VBoxContainer"]
|
[node name="scorecard_container" type="VBoxContainer" parent="GameUI/Scoreboard/VBoxContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
|
|
||||||
[node name="Button" type="Button" parent="GameUI"]
|
[node name="StartButton" type="Button" parent="GameUI"]
|
||||||
layout_mode = 0
|
layout_mode = 0
|
||||||
offset_left = 132.0
|
offset_left = 132.0
|
||||||
offset_top = 97.0
|
offset_top = 97.0
|
||||||
|
|
@ -327,6 +327,14 @@ offset_right = 228.0
|
||||||
offset_bottom = 128.0
|
offset_bottom = 128.0
|
||||||
text = "Start Game"
|
text = "Start Game"
|
||||||
|
|
||||||
|
[node name="ResetButton" type="Button" parent="GameUI"]
|
||||||
|
layout_mode = 0
|
||||||
|
offset_left = 170.0
|
||||||
|
offset_top = -125.0
|
||||||
|
offset_right = 228.0
|
||||||
|
offset_bottom = -94.0
|
||||||
|
text = "Reset"
|
||||||
|
|
||||||
[node name="PlayerSpawns" type="Node2D" parent="."]
|
[node name="PlayerSpawns" type="Node2D" parent="."]
|
||||||
|
|
||||||
[node name="Point" type="CollisionShape2D" parent="PlayerSpawns"]
|
[node name="Point" type="CollisionShape2D" parent="PlayerSpawns"]
|
||||||
|
|
@ -474,5 +482,6 @@ stream = ExtResource("7_j5wjh")
|
||||||
volume_db = -20.037
|
volume_db = -20.037
|
||||||
autoplay = true
|
autoplay = true
|
||||||
|
|
||||||
[connection signal="pressed" from="GameUI/Button" to="." method="_on_start_button_pressed"]
|
[connection signal="pressed" from="GameUI/StartButton" to="." method="_on_start_button_pressed"]
|
||||||
|
[connection signal="pressed" from="GameUI/ResetButton" to="." method="_on_reset_button_pressed"]
|
||||||
[connection signal="finished" from="IntroPlayer" to="." method="_on_intro_player_finished"]
|
[connection signal="finished" from="IntroPlayer" to="." method="_on_intro_player_finished"]
|
||||||
|
|
|
||||||
|
|
@ -152,3 +152,7 @@ func _on_start_button_pressed() -> void:
|
||||||
flyover_player.stop()
|
flyover_player.stop()
|
||||||
intro_player.play()
|
intro_player.play()
|
||||||
start_button.disabled = true
|
start_button.disabled = true
|
||||||
|
|
||||||
|
|
||||||
|
func _on_reset_button_pressed() -> void:
|
||||||
|
get_tree().reload_current_scene()
|
||||||
|
|
|
||||||
|
|
@ -15,6 +15,10 @@ run/main_scene="uid://jo1lu66y1gx6"
|
||||||
config/features=PackedStringArray("4.4", "GL Compatibility")
|
config/features=PackedStringArray("4.4", "GL Compatibility")
|
||||||
config/icon="res://icon.svg"
|
config/icon="res://icon.svg"
|
||||||
|
|
||||||
|
[autoload]
|
||||||
|
|
||||||
|
Twitch="*res://twitch.tscn"
|
||||||
|
|
||||||
[display]
|
[display]
|
||||||
|
|
||||||
window/stretch/mode="canvas_items"
|
window/stretch/mode="canvas_items"
|
||||||
|
|
|
||||||
1
twitch.gd
Normal file
1
twitch.gd
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
extends Node
|
||||||
1
twitch.gd.uid
Normal file
1
twitch.gd.uid
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
uid://damxpifvhhb78
|
||||||
6
twitch.tscn
Normal file
6
twitch.tscn
Normal file
|
|
@ -0,0 +1,6 @@
|
||||||
|
[gd_scene load_steps=2 format=3 uid="uid://cg12qp1rk55ai"]
|
||||||
|
|
||||||
|
[ext_resource type="Script" uid="uid://damxpifvhhb78" path="res://twitch.gd" id="1_xmflv"]
|
||||||
|
|
||||||
|
[node name="Twitch" type="Node"]
|
||||||
|
script = ExtResource("1_xmflv")
|
||||||
Loading…
Add table
Add a link
Reference in a new issue