Improve prestige buff

This commit is contained in:
2026-05-07 22:27:08 +02:00
parent 1ccb498947
commit b0146dea04
7 changed files with 32 additions and 37 deletions

View File

@@ -10,7 +10,6 @@ var _connections: Array = []
func _ready() -> void:
mouse_filter = Control.MOUSE_FILTER_IGNORE
## Replace all connections and redraw.
func set_connections(connections: Array) -> void:
_connections = connections

View File

@@ -52,13 +52,13 @@ func _refresh_connections() -> void:
_connection_overlay.set_connections(connections)
## Recursively collects all PrestigeBuffGraphTile nodes from a container.
## Collects all PrestigeBuffGraphTile nodes rooted at `from`, recursing into every child.
func _collect_tiles(from: Node, out_tiles: Array[PrestigeBuffGraphTile]) -> void:
for child in from.get_children():
if child is PrestigeBuffGraphTile:
out_tiles.append(child)
elif child is Container:
_collect_tiles(child, out_tiles)
var found: Array[Node] = from.find_children("*", "PrestigeBuffGraphTile", true, false)
for node in found:
var tile := node as PrestigeBuffGraphTile
if tile:
out_tiles.append(tile)
func _refresh_balance() -> void:
if _game_state == null: