summaryrefslogtreecommitdiff
path: root/scripts/splashscreen.gd
diff options
context:
space:
mode:
authorLogan <logan@cflip.net>2023-02-01 17:44:17 -0700
committerLogan <logan@cflip.net>2023-02-01 17:44:17 -0700
commitdd91a66238b1df039321c9a11e7c038e50b45c21 (patch)
tree29a8c79a5155a0f9e7fb4e88f80ebdf7bbad5bda /scripts/splashscreen.gd
parent0d0be8268275ca42dae0899e405bcc000c445a20 (diff)
Added music scene singleton
Diffstat (limited to 'scripts/splashscreen.gd')
-rw-r--r--scripts/splashscreen.gd8
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/splashscreen.gd b/scripts/splashscreen.gd
index a78d5f7..01291e9 100644
--- a/scripts/splashscreen.gd
+++ b/scripts/splashscreen.gd
@@ -1,7 +1,15 @@
extends Node
func _ready():
+ global_variables.startup = true
$AnimationPlayer.play("splashscreen")
func _on_AnimationPlayer_animation_finished(_splashscreen):
+ change_scene()
+
+func _input(event):
+ if event.is_action_pressed("escape"):
+ change_scene()
+
+func change_scene():
get_tree().change_scene("res://scenes/mainmenu.tscn")