Add passive F2 diagnostics overlay with persistent session visibility

This commit is contained in:
UnixNight committed 2026-10-25 02:17:40 -04:00
1 parent 20aa1bc2b9
commit 113e9a41cc
17 files changed
+414 -24

No files matched your search

+41 -1
View File
@@ -1,4 +1,4 @@
# F1 debug menu
# Debug menu and live overlay
User-requested modern investigation tools, separate from recovered original UI.
F1 works in the game, during cutscenes and practice prompts, and in scene inspection.
@@ -8,6 +8,7 @@ audio. Closing resumes the previous mode. No new assets or dependencies are need
| Key | Action |
| --- | --- |
| F1 | Open/close |
| F2 | Toggle live diagnostics without pausing |
| Up/Down | Select a row |
| Left/Right | Change selected level, startpoint or staged SCENE task value |
| Page Up/Down | Change staged SCENE value by10 |
@@ -62,6 +63,45 @@ It also enables Force Control through the menu and verifies actual movement whil
Carl's MCA is still playing. Director checks cover disabling the override, shot
changes, scene reset and the normal completion music handoff.
## Live diagnostics (F2)
F2 toggles a compact panel in the upper-left corner while gameplay, cutscenes and
audio continue. The F1 menu also offers Live Overlay; opening F1 replaces the live
panel temporarily, preserving its setting. F2 works while F1 or practice is open
without changing their pause state. Visibility persists through resets and scene
loads within the process; it is not stored in TSK. `--debug-overlay` starts enabled.
Twelve bounded rows show measured FPS/frame milliseconds; level/start; root XYZ;
velocity XYZ; yaw/speed/turn rate; ground/pose/energy; control/force/pause; SCENE/
score/jetpack state and burst timer; actual camera mode/far plane; cutscene/shot/
blocked state; movement counters; and reported issue/Vulkan-error/frame counts.
STRT, orbit, gameplay and cutscene modes use the actual rendered view selection;
orbit reports its own radius-derived far plane. A paused player/control lock is
separate from pausing the whole simulation.
Timing measures rendered-loop wall intervals, including rendering/presentation,
independently of the simulation clock. It shows an initial running mean, then
publishes half-second window averages. Text uses the preceding timing sample;
the first frame has no measurement yet. This is frame timing, not GPU profiling.
Timing continues while hidden so enabling the panel has current samples.
Motion fields describe the player simulation; standalone mesh inspection has no
running player and displays zero/default motion values.
DebugDiagnostics is read-only and retains timing/visibility across scene rebuilds.
DebugMenuOverlay reuses the existing font and fixed vertex ranges with a smaller,
content-sized panel. Gameplay state, pause policy and original HUD stay separate.
There are no added assets or dependencies.
DebugDiagnosticsTests verifies timing, finite zero/invalid cases, live snapshots,
camera selection, culture-independent formatting and label bounds. The24-frame
`--smoke-debug-overlay` SDL check verifies F2/repeat handling, movement without
pause, hide/show, F1 priority, visibility preference, menu action and800x600 resize.
Native Linux evidence: artifacts/live-debug-window.log; zero Vulkan validation
errors. The existing F1/force-control SDL check also passes. Full regression and
cross-scene results are in progress.md; no new Windows runtime check is claimed.
The headless lab/VR04/lab check preserves enabled state and frame samples1/2/3,
with zero Vulkan errors (artifacts/live-debug-return.log).
Native Linux GTX1070 window test passes with zero Vulkan validation errors:
artifacts/debug-window.log. GPU screenshots debug-menu.png and debug-window.open.ppm
show the menu. Source/build/regression evidence does not constitute new native