aboutsummaryrefslogtreecommitdiff
path: root/game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd
diff options
context:
space:
mode:
author Hop311 <Hop3114@gmail.com>2024-03-04 23:51:41 +0100
committer GitHub <noreply@github.com>2024-03-04 23:51:41 +0100
commiteaae420cd2aca224d15f6276624c2fab882c978a (patch)
treebacc8f4094eff5514a94b3852e9cec9c28391669 /game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd
parent521f7d3d156f42535fb7574fb36f2726e9d13885 (diff)
parente2077a0d93be8b2dd48f1ee680809420f1f690d7 (diff)
Merge pull request #211 from OpenVicProject/for-loop-types
Add types to GDScript for-loop variables
Diffstat (limited to 'game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd')
-rw-r--r--game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd6
1 files changed, 2 insertions, 4 deletions
diff --git a/game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd b/game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd
index 646c694..b50ee28 100644
--- a/game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd
+++ b/game/src/Game/Menu/LobbyMenu/LobbyPanelButton.gd
@@ -29,8 +29,7 @@ func set_text(value : StringName) -> void:
func _get_minimum_size() -> Vector2:
var result := Vector2()
- for child in get_children():
- child = child as Control
+ for child : Control in get_children():
if child == null or not child.visible:
continue
if child.top_level:
@@ -82,8 +81,7 @@ func _notification(what : int) -> void:
_size -= style.get_minimum_size()
offset += style.get_offset()
- for child in get_children():
- child = child as Control
+ for child : Control in get_children():
if child == null or not child.is_visible_in_tree() or child.top_level:
continue