giants-godot/ui/menus/main_menu.gd

17 lines
374 B
GDScript

extends BaseUI
onready var options_menu = preload("res://ui/menus/options_menu.tscn").instance()
func _ready():
options_menu.called_ui = self
func _on_Start_pressed():
get_tree().change_scene("res://scenes/playground.tscn")
func _on_Quit_pressed():
get_tree().quit()
func _on_Options_pressed():
get_parent().add_child(options_menu)
get_parent().remove_child(self)