restart screen
uncoupled title screen and level0
This commit is contained in:
parent
d464e0499b
commit
d17b16ad5b
8 changed files with 94 additions and 7 deletions
|
|
@ -1,8 +1,14 @@
|
|||
extends Control
|
||||
|
||||
func _ready() -> void:
|
||||
var level_scene: PackedScene = load("res://levels/level_0.tscn")
|
||||
var level: Level = level_scene.instantiate()
|
||||
level.active = false
|
||||
get_tree().current_scene.add_sibling.call_deferred(level)
|
||||
|
||||
func _on_play_pressed() -> void:
|
||||
Level.start_game()
|
||||
get_tree().current_scene = Level.level
|
||||
queue_free()
|
||||
|
||||
func _on_quit_pressed() -> void:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue