Files
BT411/docs/CONTROLS.md
T
arcattackandClaude Opus 5 150961176c merge fix-ups: the four review findings + a build portability gate the merge exposed
Applied on top of the glass-cockpit-refit merge, all from the pre-merge review:

1. README CONTROLS TABLE REWRITTEN for the new default board.  It still taught
   "W/S throttle, A/D turn" while the defaults moved flight to the numpad and
   handed the letter rows to the MFD banks -- a fresh install would read
   controls that do not work.  The new table teaches the numpad flight block,
   the panel-on-your-keys groups, F7 for control mode (was M), backtick for the
   camera (was V), the coolant valves on 1-3/QWE with the detent warning kept,
   and PgUp/PgDn volume.  UPGRADERS ARE TOLD EXPLICITLY that their preserved
   bindings.txt keeps their old keys, and that deleting it opts into the board.

2. BACKTICK VIEW-TOGGLE GUARDED.  The bindings-row-wins rule (KeyHasBinding)
   covered V and J/K/L but not backtick itself, which polled unconditionally --
   and BACKTICK is a nameable, unbound key, so binding it to a button
   double-dispatched (button + camera).  Both halves of the view poll are now
   guarded.

3. ENVIRON.INI REFUSES ONE-SHOTS.  The loader applied ANY key=value line, and
   BT_JOYCONFIG in the file would defeat the #66 one-shot in a sneaky way: the
   wizard DELETES the process var after running, so in every relaunched child
   there is no real env var left to win over the file -- capture wizard at
   every mission start.  BT_JOYCONFIG is now skipped with the reason in the
   template header, which also warns that test/debug hooks (BT_MP_FORCE_DMG
   and friends) do not belong in a file that silently persists forever.

4. VOLUME DOCUMENTED EVERYWHERE IT WAS MISSING.  CONTROLS.md gains the
   PgUp/PgDn row (the old "- / = (see below)" cell pointed at a note that never
   mentioned volume) and the note that the keys moved so they no longer share a
   key with anything in any layout; the bindings template header reserves
   PgUp/PgDn informally.

5. L4KEYLIGHT BUILD GATE (found by building the merge on this machine).  The
   C++/WinRT Dynamic Lighting TU does not compile against SDK 10.0.19041 --
   its bundled cppwinrt fails inside winrt/base itself (C2039 'wait_for').
   CMake now detects an SDK older than 10.0.22000 and builds a dormant stub
   with the same five-function scalar interface (logs once at Start, identical
   behaviour otherwise) -- extending the feature's own runtime philosophy
   ("no Dynamic Lighting -> log once, stay dormant") to build time.  Dynamic
   Lighting is a Windows 11 22H2 feature, so nothing real is lost on an older
   build machine, and machines with a newer SDK build the real mirror
   unchanged.

VERIFIED on the merged tree (4.11.572):
  * build clean -- 0 compile errors; the 40 /FORCE-tolerated unresolved
    externals are byte-identical to every pre-merge build (20
    CreateStreamedSubsystem + 20 DefaultData; the earlier claim that all 40
    were CSS was shorthand -- corrected here for the record).
  * solo boot: environ.ini template written + loaded, mode resolver announces
    the surround, historical bands L276/R276/T223/B336 confirmed, keylight
    stub logs its dormant line, BT_SHOT capture shows the under-glass button
    treatment and the corrected hat labels, 0 faults.
  * PgUp/PgDn volume PROVEN LIVE via injected keys: 5%->10%->15%->10%, saved
    to volume.cfg.  (Side catch: content\volume.cfg had been sitting at 0.00
    from an old test -- anyone using this tree had a silent game; reset.)
  * full relay cycle on the merged exe: 2 pods staged, launch pair, mission,
    StopMission, round RESET -- all clean.
  * all three console suites still pass; checkctx CLEAN.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-07-26 13:24:22 -05:00

116 lines
5.5 KiB
Markdown

# BattleTech 4.11 — controls reference
Two ways to fly: the **keyboard/pad** (the ~25 core actions) and the **cockpit panel**, where
every one of the pod's 72 illuminated buttons is mouse-clickable exactly where it sat in the
cabinet. Left-click presses; **right-click latches** a button held.
Rebind keys in `content\bindings.txt` (delete it to regenerate the defaults).
Cockpit layout and display sizes live in `content\environ.ini` (likewise self-documenting).
---
## Keyboard — the keyboard IS the button board
The letter and number rows are the MFD button banks, laid out where they sit on the panel.
Flight lives on the number pad so the board stays free.
### Flight — the number pad
| Key | Action | | Key | Action |
|---|---|---|---|---|
| NumPad 8 / 2 | torso aim up / down | | NumPad 7 / 9 | left / right pedal |
| NumPad 4 / 6 | torso twist left / right | | NumPad 5 | all stop |
| NumPad 0, Space | main trigger | | NumPad 1 / 3 / . | pinky / middle / upper |
| Shift / Ctrl | throttle up / down (the lever sticks) | | Alt | reverse thrust |
| ← ↓ → | look left / behind / right | | ↑ | torso centre |
| ` | cockpit / chase camera | | PgUp / PgDn | volume up / down (saved) |
**You spawn in BASIC control mode.** In BASIC the stick steers and the pedals do nothing.
Press **F7** once for MID, where the pedals steer and the stick twists the torso — the full
pod experience. If "turning doesn't work", this is why.
### The panel — letter and number rows
```
UPPER DISPLAYS Heat / coolant Engineering Comm / hotbox
top row 1 2 3 4 | 5 6 7 8 | 9 0 - =
bottom row Q W E R | T Y U I | O P [ ]
0x2F..0x2C 0x27..0x24 0x37..0x34
0x2B..0x28 0x23..0x20 0x33..0x30
LOWER DISPLAYS Left Weapons Right Weapons
top row A S D F (G unbound) H J K L
bottom row Z X C V (B unbound) N M , .
0x0F..0x0C 0x07..0x04
0x0B..0x08 0x03..0x00
COLUMNS beside the map
left F1 zoom+ F2 zoom- F3 thermal F4 CROUCH F5 lamp F6 display
right F7 control mode F8 - F9..F12 Generators A-D
```
G and B are deliberately unbound: they are the physical gap between the lower clusters.
**1 2 3 Q W E are the coolant valves** and the detents run 1 - 5 - 50 (max) - **0 (CLOSED)** -
back to 1. One press past max shuts that loop off and everything on it overheats; boosting one
loop starves the others, since the supply is shared. **4** is the flush (hold it) and **R**
re-balances every valve.
The weapon and engineering displays are **page-gated**: on the Quad page the outer buttons jump
to a populated Eng page; on an Eng page they drive generator select A-D, bus mode, coolant
toggle, trigger configure, and **eject** (tap to clear a jam, hold ~3 s to jettison a burning
ammo bay before it detonates).
### What a bound key gives up
Binding a key removes it from the authentic 1995 typed-hotkey channel so it cannot
double-dispatch. This board binds nearly everything, so those hotkeys are given up by design:
`5` = MFD1 Quad page, `z` = MFD3 Eng1, `t/y/u/i/o` = pilot select, `+`/`-` = target zoom.
Unbind a key in `bindings.txt` to get its 1995 meaning back. (The old `-`/`=` VOLUME keys
moved to **PgUp/PgDn** -- they no longer share a key with anything, in any layout.) Same rule for the built-ins:
**`** is the view toggle (V is a board button now), and J/K/L cycle the MFD preset pages only
while unbound.
Addresses with no function at all — the pod never wired them — are `0x16` `0x17` `0x19`
`0x1E` `0x1F` and `0x38`-`0x3E`.
## Controllers
An **Xbox controller** works out of the box.
**Flight sticks, HOTAS and pedals:** run `joyconfig.bat` once. A wizard asks you to move each
control in turn — stick, twist, throttle, fire buttons — writes the bindings, and drops you into
the solo menu to try them. It only rewrites its own section of `bindings.txt`, so hand edits
elsewhere in the file survive.
**Mouse buttons** are bindable like any key — `MOUSE4`, `MOUSE5` (the side buttons),
`MOUSEMIDDLE`, and `MOUSELEFT`/`MOUSERIGHT`. The side and middle buttons are the free ones; left
and right are how you press cockpit buttons, so binding those fires on every panel click too.
Mouse *movement* is not bindable — see `docs/MOUSELOOK_PLAN.md`.
```
key MOUSE4 button 0x40 # side button = main trigger
key MOUSE5 button 0x46 # side button = middle thumb
```
**RGB keyboards** with Windows Dynamic Lighting mirror the panel: any key you have bound to a
lamp button glows in the panel's own colours and flashes in step with the on-screen buttons. Turn
it off with `BT_KEYLIGHT=0` in `environ.ini`.
---
## Cockpit layout
Set these in `content\environ.ini`:
- **`BT_MFD_SCALE`** (and `_UL`/`_UC`/`_UR`/`_LL`/`_LR`) — size of the five MFDs, as a percentage
of their pod size. Turn them up if you want to actually read them while you fly.
- **`BT_RADAR_SCALE`**, **`BT_RADAR_POS`** — size the map, and move it out of the middle of the
road: `CENTER`, `LEFT`, `RIGHT`, `MIDLEFT`, `MIDRIGHT`.
- **`BT_GLASS_PANELS=1`** — break every display out into its own desktop window instead of the
composited cockpit. Good for reading one display at full size.
Run with **`-fit`** for a borderless window over the whole monitor. The cockpit scales to any
window shape at one uniform scale, so nothing ever stretches — a window that isn't the cockpit's
shape just gets black bars.