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.
This commit is contained in:
Dan 2024-05-15 10:42:16 +01:00
parent a62cd6018e
commit 2a9e78b52e
37 changed files with 216 additions and 248 deletions

View file

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