newlon/scripts/gui/menu_buttons.gd

25 lines
634 B
GDScript

extends Node
func _on_play_button_pressed() -> void:
LevelController.call("StartLevel",preload("uid://dd3yegl1xo44m"),preload("uid://ctbue7dex4umy"))
$ChannelPlayer.call("Play")
func _on_exit_button_pressed() -> void:
get_tree().root.propagate_notification(NOTIFICATION_WM_CLOSE_REQUEST)
get_tree().quit()
$ChannelPlayer.call("Play")
func _on_button_pressed() -> void:
$"../AboutWindow".popup_centered()
$ChannelPlayer.call("Play")
func _on_almanach_button_pressed() -> void:
$"../Almanach".visible = true
$ChannelPlayer.call("Play")
func _on_splash_button_pressed() -> void:
$"../PrototypeWindow".popup_centered()