chore: relocate responsive validation report
This commit is contained in:
@@ -0,0 +1,125 @@
|
||||
# Task 5 — Visual validation and responsive HUD completion
|
||||
|
||||
## Scope completed
|
||||
|
||||
Task 5 closes the visual-capture and responsive-HUD issues without changing gameplay, map generation, combat, or input behavior.
|
||||
|
||||
### Root-cause audit of inherited changes
|
||||
|
||||
The three pre-existing working-tree edits were retained because they address actual capture-contract causes:
|
||||
|
||||
1. **Explored-fog validator (`scripts/check-visual-capture.py`)**
|
||||
- The old detector required the single RGB value `(19, 29, 39)`.
|
||||
- Actual texture-preserving fog is a range of dark blue-shifted pixels: floor texture and GPU blend rounding make a renderer-independent exact RGB assertion invalid.
|
||||
- The replacement accepts only a bounded, blue-shifted palette (`R 4–14`, `G 8–22`, `B 17–32`, with channel-separation guards), excluding HUD chrome and unmodulated brown terrain.
|
||||
- `tests/scripts/test_godot_import_runners.sh` now emits a representative accepted palette pixel `(9, 14, 23)`, covering the updated contract rather than encoding an obsolete exact renderer sample.
|
||||
|
||||
2. **Deterministic exit capture (`scripts/game/game.gd`)**
|
||||
- `Camera2D` scroll is applied during the frame cycle. Capturing immediately after moving the player to the exit could retain the previous camera framing.
|
||||
- The capture now calls `camera.force_update_scroll()` before its frame waits.
|
||||
- The entry cell is outside the exit crop, so it could not prove the remembered/explored rendering contract. The deterministic exit state explicitly retains a neighboring exit floor tile as explored while removing it from visible cells.
|
||||
- The visual runner then verifies both visible terrain and remembered texture-preserving fog in the actual exit image.
|
||||
|
||||
### Responsive 1280×720 correction
|
||||
|
||||
Manual inspection of the original 1280×720 capture showed the three header text rows were too tightly stacked: the dynamic header values intruded into the lower edge of the top bar and were visibly clipped/overlapped by the header ornament. The underlying issue was that the rectangles scaled to 2/3 but all label font overrides remained at their desktop sizes; also, the `ResponsiveLayout` chrome painted after the direct HUD labels.
|
||||
|
||||
The repair:
|
||||
|
||||
- places the decorative `ResponsiveLayout` chrome behind direct live HUD values via `z_index = -1` in `Game.tscn`;
|
||||
- scales the HUD’s text overrides with the existing artboard scale (bounded by the same 0.66 compact minimum);
|
||||
- moves the dynamic header value baseline from reference y=78 to y=75, giving the 1280 layout sufficient top-bar height;
|
||||
- adds `test_compact_1280_layout_scales_header_text_and_keeps_it_inside_the_top_bar`, which asserts the compact 11px header font, top-bar containment, and adequate label height.
|
||||
|
||||
No gameplay logic changed.
|
||||
|
||||
## Manual capture inspection
|
||||
|
||||
### 1920×1080
|
||||
|
||||
- Captured the initial state and deterministic exit state.
|
||||
- The full shell is legible and the live header text remains clear of the ornament; no material clipping or overlap observed.
|
||||
- The rails, command band, and centered map frame are distinct. The header deliberately uses three compact rows, but they have visible separation at this resolution.
|
||||
- The exit capture shows visible terrain, unknown fog, and a dark blue remembered-terrain patch as required by the visual contract.
|
||||
|
||||
### 1280×720
|
||||
|
||||
- Before the repair, the header text was visibly crowded and partly clipped/overdrawn at the lower header edge; command/rail texts were correspondingly cramped.
|
||||
- After the repair, header rows are contained in the top bar and no longer overdraw the ornament. Rail and command text are smaller but readable for a compact 720p presentation.
|
||||
- The visual density remains necessarily high because this is the complete 1920×1080 artboard at two-thirds scale; however, no material header clipping/overlap remains.
|
||||
|
||||
Temporary comparison captures were removed after inspection; no capture PNG, `.import`, or other artifact is included in the commit.
|
||||
|
||||
## Cleanup
|
||||
|
||||
- Terminated the lingering `godot4 --headless --script res://tests/tmp_inspect_hud.gd` process.
|
||||
- Removed `tests/tmp_inspect_hud.gd` and its UID if present.
|
||||
- Removed the one-off HUD diagnostic script after use.
|
||||
- Emptied generated `artifacts/` before commit. Existing Godot-generated `.import` files remain ignored and untracked.
|
||||
|
||||
## Verification
|
||||
|
||||
All commands completed successfully:
|
||||
|
||||
| Command | Result |
|
||||
| --- | --- |
|
||||
| `./scripts/test-unit.sh` | **221 / 221** tests passed, **34,509** assertions |
|
||||
| `./scripts/run-visual-check.sh` | Passed initial + exit capture measurements |
|
||||
| `./tests/scripts/test_godot_import_runners.sh` | Passed |
|
||||
| `./scripts/verify.sh` | Passed unit, integration, E2E, visual, and strict parity gates |
|
||||
|
||||
`./scripts/verify.sh` results:
|
||||
|
||||
| Suite | Passing | Tests | Assertions |
|
||||
| --- | ---: | ---: | ---: |
|
||||
| Unit | 221 | 221 | 34,509 |
|
||||
| Integration | 19 | 19 | 1,696,729 |
|
||||
| E2E | 78 | 78 | 676 |
|
||||
|
||||
Visual measurements reported by the final verifier:
|
||||
|
||||
- `visual-check.png`: `dungeon_non_black_pixels=1102464`, `visible_pixels=82944`, `explored_pixels=18965`, `explored_luminance=0.004`, `unknown_pixels=890112`, `unknown_luminance=0.001`.
|
||||
- `visual-check-exit.png`: `dungeon_non_black_pixels=1102464`, `visible_pixels=10368`, `explored_pixels=18965`, `explored_luminance=0.004`, `unknown_pixels=976128`, `unknown_luminance=0.001`.
|
||||
- Strict parity: `matrix gate passed (rows=43 invalid=0)`.
|
||||
|
||||
Godot emitted pre-existing GUT invalid-UID and resource-cleanup warnings; none were script/parse/test failures, and all verifier commands exited 0.
|
||||
|
||||
## Round 1 Task 5 — reproducible compact capture follow-up
|
||||
|
||||
The visual runner now performs three real captures: the existing 1920×1080 initial and exit captures, plus a separate windowed `1280x720` run using `--visual-check-compact`. The game’s capture hook recognizes that user argument and writes `artifacts/visual-check-compact.png` without changing the initial or exit state preparation. The menu capture shortcut also recognizes the compact mode so the run starts deterministically.
|
||||
|
||||
The PNG checker now maps each supported capture filename to its required dimensions, scales the central dungeon measurement crop from the 1920×1080 reference artboard, and applies the existing content contract to the compact image. Runner regression coverage uses a generated 1280×720 fixture and asserts that the visual runner passes `--windowed --resolution 1280x720` and produces the compact artifact.
|
||||
|
||||
### Round 1 verification evidence
|
||||
|
||||
- `./tests/scripts/test_godot_import_runners.sh` — passed; fake runner validated import ordering, compact dimensions, content, and resolution flags.
|
||||
- `./scripts/run-visual-check.sh` — passed; initial and exit remain 1920×1080, compact is 1280×720.
|
||||
- `./scripts/verify.sh` — passed unit, integration, E2E, visual, and strict parity gates (`matrix gate passed`, 43 rows).
|
||||
- `artifacts/visual-check-compact.png` — measured as `1280x720`; content measurement passed with `dungeon_non_black_pixels=489984`, `visible_pixels=36926`, `explored_pixels=8227`, `unknown_pixels=393984`.
|
||||
- The generated compact PNG was inspected after capture; it shows the complete compact HUD/map composition with no capture truncation or black-frame failure.
|
||||
|
||||
## Git
|
||||
|
||||
The Task 5 implementation, regression coverage, and this report are committed locally. No push was performed.
|
||||
|
||||
|
||||
# PR-4 — Responsive HUD validation hardening
|
||||
|
||||
## Scope
|
||||
|
||||
Final-review fixes for responsive HUD validation and non-16:9 presentation:
|
||||
|
||||
- Expanded the real 1280×720 layout test to require all major live HUD regions—rails, command bar, journal, prompt/help, gauges, quick slots, and minimap—to remain enclosed, readable, and outside the framed play area.
|
||||
- Added 1024×768 and 2560×1080 unit coverage for a centered 16:9 artboard, explicit letterbox/pillarbox bands, opaque dark-fantasy outside margins, and shell containment.
|
||||
- Added runtime `Artboard`, letterbox, and pillarbox nodes in `Game.tscn`; `hud.gd` sizes them from one centered reference artboard and synchronizes the minimap after rail relayout.
|
||||
- Replaced the absolute UI-kit source path in `ASSET_REGISTRY.md` with the portable pack identifier `DungeonCrawlerWorld_UI_Assets/README.md`.
|
||||
- Existing scene paths and gameplay behavior remain unchanged. The theme was not broadened to unrelated nodes because the current shell already owns the HUD theme and a CanvasLayer-wide theme would be unsafe for instantiated modal panels.
|
||||
|
||||
## Verification
|
||||
|
||||
- Targeted HUD layout: **10/10 tests passed**, 269 assertions.
|
||||
- Full `scripts/verify.sh`: unit **223/223**, integration **19/19**, E2E **78/78**, 34,650 unit assertions plus 1,696,729 integration assertions; parity matrix **43 rows, 0 invalid**.
|
||||
- Real visual runner passed 1920×1080, exit, and 1280×720 captures. Compact capture inspected at 1280×720; opaque dark-fantasy margins and contained controls are present.
|
||||
- Capture measurements: reference `visible=82944`, `explored=18965`, `unknown=890112`; exit `visible=10368`, `explored=18965`, `unknown=976128`; compact `visible=36926`, `explored=8227`, `unknown=393984`.
|
||||
|
||||
Godot/GUT emitted only existing invalid-UID, cleanup/resource, and float/int comparison warnings. No push was performed.
|
||||
@@ -1,20 +0,0 @@
|
||||
# PR-4 — Responsive HUD validation hardening
|
||||
|
||||
## Scope
|
||||
|
||||
Final-review fixes for responsive HUD validation and non-16:9 presentation:
|
||||
|
||||
- Expanded the real 1280×720 layout test to require all major live HUD regions—rails, command bar, journal, prompt/help, gauges, quick slots, and minimap—to remain enclosed, readable, and outside the framed play area.
|
||||
- Added 1024×768 and 2560×1080 unit coverage for a centered 16:9 artboard, explicit letterbox/pillarbox bands, opaque dark-fantasy outside margins, and shell containment.
|
||||
- Added runtime `Artboard`, letterbox, and pillarbox nodes in `Game.tscn`; `hud.gd` sizes them from one centered reference artboard and synchronizes the minimap after rail relayout.
|
||||
- Replaced the absolute UI-kit source path in `ASSET_REGISTRY.md` with the portable pack identifier `DungeonCrawlerWorld_UI_Assets/README.md`.
|
||||
- Existing scene paths and gameplay behavior remain unchanged. The theme was not broadened to unrelated nodes because the current shell already owns the HUD theme and a CanvasLayer-wide theme would be unsafe for instantiated modal panels.
|
||||
|
||||
## Verification
|
||||
|
||||
- Targeted HUD layout: **10/10 tests passed**, 269 assertions.
|
||||
- Full `scripts/verify.sh`: unit **223/223**, integration **19/19**, E2E **78/78**, 34,650 unit assertions plus 1,696,729 integration assertions; parity matrix **43 rows, 0 invalid**.
|
||||
- Real visual runner passed 1920×1080, exit, and 1280×720 captures. Compact capture inspected at 1280×720; opaque dark-fantasy margins and contained controls are present.
|
||||
- Capture measurements: reference `visible=82944`, `explored=18965`, `unknown=890112`; exit `visible=10368`, `explored=18965`, `unknown=976128`; compact `visible=36926`, `explored=8227`, `unknown=393984`.
|
||||
|
||||
Godot/GUT emitted only existing invalid-UID, cleanup/resource, and float/int comparison warnings. No push was performed.
|
||||
Reference in New Issue
Block a user