Workstream A prototype: play without the cockpit
Splits the control surface the game consumes from the RIO board into RIOBase (8 virtuals + the five analog scalars); the serial RIO is now one implementation of it. Adds two new ones: - PadRIO (L4CONTROLS=PAD): in-process RIO speaking the full surface from an XInput controller + PC keyboard using vRIO's default profile (left stick/WASD = stick, triggers/Q,E = pedals, right stick Y/PgUp,PgDn = rate throttle that holds position, A/Space = trigger, B/R = reverse, dpad/arrows = hat, Start,Back/F1,F2 = config). Samples in GetNextEvent so button latency does not depend on the 15 s menu-time analog cadence; hot-plugs pads; L4PADFLIP=XY inverts stick axes; lamp commands land in lampState[] for the planned on-screen cockpit panel. The stock VTVRIOMapper/lamp/button path runs unchanged. - PlasmaScreen (L4PLASMA=SCREEN): the 128x32 plasma glass as a desktop window in plasma orange (L4PLASMASCALE, default x4), rendering the same Video8BitBuffered surface the gauge system always drew; no COM port. Verified in the sandbox with vRIO off and no serial devices: boots to a running mission, controller hot-detected, plasma window drawing live game content (score readout). BUILD.md 4 documents the desktop environ.ini and bindings; roadmap updated. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -96,6 +96,47 @@ For runtime debugging the v143 build produces full PDBs — run
|
||||
`cdb -g -G -lines -y Release rpl4opt.exe ...` from the working directory
|
||||
(cdb ships in this machine's Windows Kits).
|
||||
|
||||
### Running without the cockpit (Workstream A prototype)
|
||||
|
||||
Two new environment options remove the hardware dependency entirely:
|
||||
|
||||
- **`L4CONTROLS=PAD;KEYBOARD`** — selects **PadRIO**
|
||||
([MUNGA_L4/L4PADRIO.cpp](MUNGA_L4/L4PADRIO.cpp)), an in-process RIO that
|
||||
speaks the full RIO control surface (buttons, axes, lamps) from an XInput
|
||||
controller + the PC keyboard. The stock `VTVRIOMapper` path runs unchanged.
|
||||
Hot-plugging works; with no controller it falls back to keyboard only.
|
||||
- **`L4PLASMA=SCREEN`** — renders the 128×32 plasma display as its own
|
||||
desktop window ("Plasma Display", plasma orange, `L4PLASMASCALE` sets the
|
||||
pixel size, default 4). No COM port. Closing the window hides it.
|
||||
|
||||
Bindings (vRIO's default profile, condensed):
|
||||
|
||||
| Input | Pod control |
|
||||
|-------|-------------|
|
||||
| Left stick / WASD | joystick X/Y |
|
||||
| LT / RT, Q / E | left / right pedal |
|
||||
| Right stick Y, PgUp / PgDn | throttle (rate; position holds) |
|
||||
| A / Space | joystick trigger |
|
||||
| B / R | reverse thrust (ButtonThrottle1) |
|
||||
| DPad / arrows | joystick hat (look) |
|
||||
| X, Y, LB, RB | pinky / thumb-low / thumb-low / thumb-high |
|
||||
| Start / F1, Back / F2 | config buttons (AuxUpperRight 1 / 2) |
|
||||
|
||||
`L4PADFLIP=XY` (or `X` / `Y`) inverts the stick axes if the feel is wrong.
|
||||
Example desktop `environ.ini`:
|
||||
|
||||
```ini
|
||||
L4CONTROLS=PAD;KEYBOARD
|
||||
DPLARG=1
|
||||
L4DPLCFG=RPDPL.INI
|
||||
L4GAUGE=640x480x16
|
||||
L4PLASMA=SCREEN
|
||||
TARGETFPS=60
|
||||
```
|
||||
|
||||
Lamp commands land in `PadRIO::lampState[]` — the hook for the planned
|
||||
on-screen cockpit panel (vRIO buttons arranged around the displays).
|
||||
|
||||
Also note: `Fail()` compiles to `abort()` in release (`MUNGA/DEBUGOFF.h`) —
|
||||
e.g. running with `L4CONTROLS=KEYBOARD` alone aborts at VTV creation because
|
||||
no keyboard-only pod mapper exists (the old CRT showed a blocking R6010
|
||||
|
||||
Reference in New Issue
Block a user