fix(ui): Phase K live-test fixes pt4 — collision wires default OFF, refresh DebugPanel cheat-sheet

User reported "I can't turn off collision wires" — root cause was
two-fold: the wires defaulted to ON at startup so the user saw
them every launch, and the DebugPanel's keybind cheat-sheet
still listed the pre-K.1c retail-default-conflicting bindings
(F1/F2/F3/F7/F8/F9/F10 etc.) instead of the Ctrl+F* aliases the
retail-faithful keymap moved them to.

Changes:

- _debugCollisionVisible defaults to FALSE. Ctrl+F2 toggles it
  on (toast: "Collision wireframes ON"); the DebugPanel →
  Diagnostics → "Toggle collision wires" button toggles too.

- DebugPanel "Help" cheat-sheet rebuilt to reflect the actual
  retail-default + Phase K bindings: Ctrl+F1 (debug), Ctrl+F2
  (collision wires), Ctrl+Shift+F (free-fly), F11 (Settings),
  W/X = forward/back, A/D = turn, Z/C = strafe, Q = autorun
  toggle, Shift = walk modifier, Y/G/H/B = postures,
  Hold MMB = instant mouse-look, Hold RMB = orbit, Tab =
  focus chat input. The user no longer has to read the source
  to find a working binding.

Tests stay 1222 green.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Erik 2026-04-26 14:53:16 +02:00
parent 785dd92378
commit 94e9cbcf76
2 changed files with 29 additions and 16 deletions

View file

@ -27,7 +27,11 @@ public sealed class GameWindow : IDisposable
private Shader? _meshShader;
private TextureCache? _textureCache;
private DebugLineRenderer? _debugLines;
private bool _debugCollisionVisible = true;
// K-fix4 (2026-04-26): default OFF. The orange BSP / green cylinder
// wireframes are noisy outdoors and confuse first-time users into
// thinking they're a rendering bug. Ctrl+F2 toggles, the DebugPanel
// → Diagnostics → "Toggle collision wires" button toggles too.
private bool _debugCollisionVisible = false;
private int _debugDrawLogOnce = 0;
// Phase I.2: the old StbTrueTypeSharp DebugOverlay was deleted in

View file

@ -44,21 +44,30 @@ public sealed class DebugPanel : IPanel
/// </summary>
private static readonly (string Key, string Action)[] Keybinds =
{
("Esc", "exit fly / player / close window"),
("Tab", "toggle player mode (when in-world)"),
("F", "toggle fly camera"),
("F1", "toggle this debug panel"),
("F2", "toggle collision wireframes"),
("F3", "console dump (pos + nearby objects)"),
("F7", "cycle time-of-day override"),
("F8 / F9", "mouse sensitivity slower / faster"),
("F10", "cycle weather"),
("W A S D", "move (player mode) / fly"),
("Mouse", "turn character / look (fly)"),
("Hold RMB", "free orbit camera around player"),
("Wheel", "zoom chase camera in / out"),
("Space", "jump"),
("Shift", "run"),
// K-fix4 (2026-04-26): refreshed for the retail-default keymap +
// Phase K input-pipeline bindings. F1-F12 alone are retail panel
// toggles; acdream debug actions live behind Ctrl+F* to avoid
// retail conflicts.
("Esc", "exit fly / close window"),
("F11", "open Settings (key rebinding etc.)"),
("Ctrl+Shift+F", "toggle free-fly camera"),
("Ctrl+F1", "toggle this debug panel"),
("Ctrl+F2", "toggle collision wireframes"),
("Ctrl+F3", "console dump (pos + nearby objects)"),
("Ctrl+F7", "cycle time-of-day override"),
("Ctrl+F8 / F9", "mouse sensitivity slower / faster"),
("Ctrl+F10", "cycle weather"),
("W / X", "run forward / backward"),
("A / D", "turn left / right"),
("Z / C", "strafe left / right"),
("Q", "autorun toggle"),
("Shift", "walk modifier (default = run)"),
("Space", "jump (hold to charge)"),
("Y G H B", "stand / sit / crouch / lie"),
("Hold MMB", "instant mouse-look"),
("Hold RMB", "free orbit camera around player"),
("Wheel", "zoom chase camera in / out"),
("Tab", "focus chat input"),
};
/// <inheritdoc />