extends Control signal closed @onready var close_button: Control = get_node_or_null("CloseButton") func _ready() -> void: visible = false if close_button != null and close_button.has_signal("pressed"): close_button.pressed.connect(close_menu) func open_menu() -> void: visible = true func close_menu() -> void: visible = false closed.emit() func handle_unhandled_input(_event: InputEvent) -> bool: return visible