From 95875cb92d5bb0d84e10f6a52f3757328088f660 Mon Sep 17 00:00:00 2001 From: Jeroen Schweitzer Date: Sun, 1 Mar 2026 00:04:22 +0100 Subject: [PATCH] fix(client): restore tiles variable for zone tint loop in fog_state The merge of visual and client branches dropped the `tiles` variable declaration. The client branch refactored bounds calculation to use `visible_positions`, but the visual branch's zone tint loop still iterates over `visible_tiles` for zone_id data. Co-Authored-By: Claude Opus 4.6 --- client/scripts/autoloads/fog_state.gd | 3 +++ 1 file changed, 3 insertions(+) diff --git a/client/scripts/autoloads/fog_state.gd b/client/scripts/autoloads/fog_state.gd index 2a862efd3..7ae8ec65a 100644 --- a/client/scripts/autoloads/fog_state.gd +++ b/client/scripts/autoloads/fog_state.gd @@ -181,6 +181,9 @@ func update_from_state() -> void: # 3. Zone tint: write zone temperature color for currently visible tiles. # Zone data is stable (tile zone never changes) so we only write on first sight. # Data persists in _tint_bytes across frames and across resizes. + # visible_tiles carries zone_id per tile (populated from snapshot "tiles" or + # "visible_tiles" with type field — see game_state.gd apply_snapshot). + var tiles := GameState.visible_tiles var tint_dirty := false for tile in tiles: if not tile is Dictionary or not tile.has("x") or not tile.has("y"):