pollen-not-included/scenes/scripts/drone_controls.gd
Dan 2a9e78b52e Refactor: Added explicit typing and void return types
- Introduced explicit typing to variables and functions across multiple scripts for better code clarity.
- Specified 'void' as the return type for functions that do not return a value.
- Removed redundant code in some scripts.
2024-05-15 10:42:16 +01:00

23 lines
No EOL
465 B
GDScript

extends HBoxContainer
@onready var buttons : Array[Node] = get_children()
func disable_buttons() -> void:
## Disable all buttons
for button : Button in buttons:
button.disabled = true
visible = false
func enable_buttons() -> void:
## Enable all buttons
for button : Button in buttons:
button.disabled = false
visible = true
func reset_button_focus() -> void:
## Reset focus on all buttons
for button : Button in buttons:
button.release_focus()