Build: the BT412 compile gate -- one tree builds the pod game and the Steam game

option(BT412 ... ON) gates the steamification layer for the merge-back into
BT411, so the unified repo serves both fronts:

- Default (BT412=ON): pod/dev game + PadRIO / plasma / front end / lobby --
  all runtime-gated, so a -egg/-net launch still behaves as 4.11.
- Pod-minimal (-DBT412=OFF, build-pod/): compiles OUT L4PADRIO, L4PADBINDINGS,
  L4KEYLIGHT, L4PLASMASCREEN, L4STEAMTRANSPORT, btl4fe, btl4console, btl4lobby.
  Seam sites carry #ifdef BT412: L4CTRL.cpp PAD token (log + ignore), L4GREND.cpp
  L4PLASMA=SCREEN (log + ignore), L4VB16.cpp (inert PadRIO stub -- call sites
  identical in both flavors), btl4main.cpp (front-end/marshal/lobby blocks out;
  zero-arg launch = 4.11 behavior).
- The NetTransport seam ALWAYS compiles -- it is the wire for both flavors
  (WinsockNetTransport, verified byte-identical to the pre-seam arcade path).
- BT412_STEAM now requires BT412 (configure-time FATAL_ERROR; negative-tested).

Verified: OFF -- clean v143 link, solo DEV.EGG mission runs (31 subsystems
tick, gait, targeting). ON -- zero-arg launch engages the front-end menu.
STEAM -- links clean, ships steam_api.dll.

Also: README/context docs for the flavors + the merge-back; corrected the stale
Phase 3b DEFERRED note (the single-window cockpit landed 07-16) and the README's
leftover 0xBD3 valve-gate claim (it is a damage/explosion hub).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Cyd
2026-07-17 15:45:45 -05:00
co-authored by Claude Fable 5
parent 0434585566
commit 335396912e
10 changed files with 177 additions and 48 deletions
+16
View File
@@ -21,6 +21,22 @@ cmake -S . -B build -G "Visual Studio 17 2022" -A Win32 \
# build:
cmake --build build --config Debug
```
### Build flavors — the `BT412` compile gate (2026-07-17, merge-back into BT411)
One tree builds both lines; `option(BT412 ... ON)` gates the steamification layer. [T2]
- **Default (`BT412=ON`)** — pod/dev game + PadRIO/plasma/front end/lobby (all runtime-gated;
a `-egg`/`-net` launch behaves as 4.11). Compile definition `BT412` set on all 3 targets.
- **Pod-minimal (`-DBT412=OFF`, dir `build-pod/`)** — compiles OUT `L4PADRIO`, `L4PADBINDINGS`,
`L4KEYLIGHT`, `L4PLASMASCREEN`, `L4STEAMTRANSPORT`, `btl4fe`, `btl4console`, `btl4lobby`.
Seam sites carry `#ifdef BT412`: `L4CTRL.cpp` PAD token (log + ignore), `L4GREND.cpp`
`L4PLASMA=SCREEN` (log + ignore), `L4VB16.cpp` (inert `PadRIO` stub struct — call sites
identical in both flavors), `btl4main.cpp` (front-end/marshal/lobby blocks compile out;
zero-arg launch = 4.11 behavior). The **NetTransport seam always compiles** — it is the wire
for both flavors (`WinsockNetTransport` verified byte-identical to pre-seam arcade behavior).
Verified: clean v143 link (no unresolved), solo `-egg DEV.EGG` runs (31 subsystems tick, gait,
targeting).
- **Steam (`-DBT412_STEAM=ON`, dir `build-steam/`)** — requires `BT412=ON` (configure-time
`FATAL_ERROR` otherwise; negative-tested).
- Links DXSDK d3d9/d3dx9/dinput8 + OpenAL/libsndfile (`engine/lib/`). DXSDK June 2010 at
`C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\` (overridable `-DDXSDK`). [T2]
- Linker uses **`/FORCE:MULTIPLE`** — tolerates the ~124 header-defined-global LNK2005s.
+45 -23
View File
@@ -19,11 +19,35 @@ implementation — its git history from commit `467934c` onward is the steamific
grouped roughly: toolchain → PadRIO input → MFD-split cockpit → front end/LocalConsole
→ NetTransport/Steam sockets → lobby → bindings/KeyLight → packaging.
**Repo rule [T0]:** `origin` = `VWE/BT412.git` only. This repo must never touch the
BT411 **remote** (the gitea URL) — no remote, no fetch/push to it. Forked at BT411
`4e72f0c` (2026-07-14). *Bringing BT411 work forward is allowed via a **local-path**
merge (`git fetch C:/vwe/BT411 master`) — that never contacts the gitea BT411 remote;
see the merge note below.*
**Repo rule [T0]:** each checkout talks ONLY to its own gitea remote — `C:\VWE\BT412`
`origin` = `VWE/BT412.git`, `C:\VWE\BT411` `origin` = `VWE/BT411.git`. Cross-repo sync
is **local-path only** (`git fetch C:/VWE/BT412 master` from BT411 and vice versa) —
never a cross remote. Forked at BT411 `4e72f0c` (2026-07-14); **merged back 2026-07-17**
(see the merge-back section below) — BT411 is now the unified repo carrying both lines
behind the `BT412` compile gate.
## Merge-back into BT411 + the `BT412` compile gate (2026-07-17)
The whole steamification line was merged **back into BT411** so one repo serves both
fronts (pod work + internet MP). Mechanics [T2]:
- BT411's head was exactly `abed41e` — the catch-up point BT412 had already merged —
so the merge was a clean **fast-forward** of BT411 onto BT412's line via a
local-path fetch (no gitea remote touched from either side). BT411's dirty
`run/run.cmd` bench edit (pod `-net 1501` restart loop) was stashed and restored.
- **Compile gate:** CMake `option(BT412 ... ON)` + compile definition `BT412` on all
three targets. Gated OUT under `-DBT412=OFF` (the pod-minimal flavor, `build-pod/`):
`L4PADRIO`, `L4PADBINDINGS`, `L4KEYLIGHT`, `L4PLASMASCREEN`, `L4STEAMTRANSPORT`,
`btl4fe`, `btl4console`, `btl4lobby`, plus `#ifdef BT412` seams in `L4CTRL.cpp`
(PAD token), `L4GREND.cpp` (`L4PLASMA=SCREEN`), `L4VB16.cpp` (inert `PadRIO` stub),
`btl4main.cpp` (front-end/marshal/lobby blocks; zero-arg = 4.11 behavior). The
**NetTransport seam always compiles** (the wire for both flavors). `BT412_STEAM`
requires `BT412` (configure-time `FATAL_ERROR`, negative-tested). All three flavors
verified: OFF solo mission un-regressed (31 subsystems, gait, targeting); ON zero-arg
front end engages; STEAM links + ships `steam_api.dll`. Details:
[[build-and-run]] §Build flavors.
- `handoff/padrio/` (the interim BT411 transfer copy, commit `2e475f4`) was retired —
superseded by the merge itself (the real modules now live in BT411; a drifting
duplicate in the same tree would be a hazard).
## BT411 catch-up merge (2026-07-14)
@@ -93,23 +117,16 @@ Verified after merge: clean build; solo front-end mode; loopback MP through the
Verified: a window titled "Plasma Display" opens and the game ticks normally beside it
(`L4GAUGE=640x480x16 L4PLASMA=SCREEN`). Note: the `L4GAUGE` gauge path binds a listen
socket at startup → a first-run Windows Firewall prompt (expected; unrelated to plasma).
- **Phase 3b (single-window MFD-split cockpit, `L4MFDSPLIT=1`) — DEFERRED 2026-07-14.**
Two blockers make this the wrong thing to land now:
1. **No BT cockpit-layout geometry.** RP412's `L4MFDVIEW` button-bank anchors/addresses
come from vRIO's `CockpitLayout` for the Red Planet pod; vRIO has **zero** BattleTech
data. The BT pod's panel geometry has no reference (needs pod photos / `l4gauge.cfg`
mining / Nick) — the clickable lamp-lit banks can't be authentically placed.
2. **BT's MFD compositing is an unfinished upstream beachhead.** Per `docs/GAUGE_COMPOSITE.md`,
only the radar/secondary surface composites on a dev box; the five mono MFDs don't
render yet (port-name mismatch, Step 2). RP412's split panes would be empty until that
upstream work lands.
3. **Merge is HIGH-risk** (quantified above): BT's 521-line L4VB16 divergence (dev-gauge
docking + a 476-line block) overlaps RP412's 402-line split rewrite in the ctor and
`Update` regions — a true hand-merge, not a drop-in. The 3-way diffs are staged in the
scratchpad (`rp412-L4VB16.diff`, `bt-L4VB16.diff`).
Prerequisite order when resumed: finish BT's MFD dev-composite (GAUGE_COMPOSITE.md Steps
23) → obtain BT cockpit geometry → then hand-merge `MFDSplitView`. Until then the game
ships single-window with the dev-gauge dock (`BT_DEV_GAUGES`) as its cockpit composite.
- **Phase 3b (single-window MFD-split cockpit, `L4MFDSPLIT=1`) — DONE 2026-07-16**
(initially deferred 2026-07-14; the blockers fell). Landed across commits `0c964c0`
`59c454b` + `2b238a8`: the 1920×1080 single-window cockpit arrangement (RP412 layout)
via the `L4VB16.cpp` hand-merge, on-screen clickable lamp-lit RIO button banks framing
the MFDs (4-above/4-below strips — BT-derived placement, not vRIO geometry, which has
no BT data), green MFD phosphor tint, button-lamp bitfield decode (subdued idle
baseline), `L4CONTROLS=PAD` as the cockpit default (before the DEV keyboard default),
the gauge NULL-source guard extended to the split path, and the backtick (`) toggle
for the secondary displays. Mouse presses inject into PadRIO as screen buttons
(`BTPadRIOScreenButton`, WndProc → `L4VB16.cpp`). [T2]
- **Phase 4 (NetTransport seam + Steam transport) — DONE 2026-07-14.** `L4NET.CPP`
taken from RP412 post-seam (all ~24 Winsock call sites now route through
`NetTransport_Get()`); BT's 3 `BT_NET_TRACE` blocks re-sited onto their code anchors
@@ -203,7 +220,12 @@ Verified after merge: clean build; solo front-end mode; loopback MP through the
machines) — untestable here (needs Steam + ≥2 accounts/machines). Procedure:
`docs/STEAM-3-MACHINE-TEST.md`. The lobby object does NOT survive the per-mission relaunch
(single-binary limitation — everyone returns to a fresh menu, not the room).
- Phase 7: packaging (`pack-dist.ps1`), KeyLight, release — remain.
- **Phase 7 (packaging) — IN PROGRESS.** `pack-dist.ps1` landed (assembles a runnable
Steam test dist; wraps the zip in a single `BT412/` folder). KeyLight landed with
Phase 2 (`L4KEYLIGHT`, gate `BT412KEYLIGHT`). Remaining: release proper (real Steam
AppID, store assets, depot config) + the Phase 6 live 3-machine test.
- **Merge-back into BT411 — DONE 2026-07-17** (see the merge-back section above): one
repo, both lines, behind the `BT412` compile gate.
## The seams (what plugs in where) [T0 unless noted]