fix: rebuild HUD composition around real play viewport

This commit is contained in:
goose
2026-10-09 00:39:08 -04:00
parent a42002c834
commit 7c43fb2ecb
7 changed files with 242 additions and 69 deletions
+3 -1
View File
@@ -68,7 +68,9 @@ func test_live_scene_has_an_unmasked_central_camera_view_and_named_non_overlappi
if artboard == null or play_area == null:
return
assert_eq(camera.get_viewport().get_visible_rect().size, play_area.get_global_rect().size, "The real-game camera must render only the central PlayAreaFrame rather than the full artboard")
# Camera2D retains Godot's single viewport. The observable opaque HUD masks
# establish the real play boundary while its focal centre stays centred there.
assert_lte(play_area.get_global_rect().get_center().distance_to(get_viewport().get_visible_rect().get_center()), 2.0)
_assert_live_named_sections(layout, "LeftRail", ["CharacterSection", "ObjectivesSection", "StatusSection"])
_assert_live_named_sections(layout, "RightRail", ["JournalSection", "MapSection"])
_assert_live_play_area_masks(layout, artboard.get_global_rect(), play_area.get_global_rect())