Controls: the keyboard bridges STAND DOWN for a live device (step 2c)

New engine query BTRIODevicePresent() (L4CTRL.cpp, ungated -- pod-correct for
the serial RIO too): device exists AND IsOperational().  Both dev input
bridges -- the mech4.cpp mapper-attr writes and the mechmppr.cpp BT_KEY_BRIDGE
block -- now gate their WRITES on it: BT_KEY_BRIDGE unset = auto (bridge only
when no device), 0 = force off (the documented pod setting, honored), else
force on.  The BT_FORCE_THROTTLE headless harness always rides the bridge.
The mapper demand READ (turn = turnDemand) always runs.

Verified live (glass build, PAD): OS-injected LSHIFT hold slews the PadRIO
throttle 0 -> 0.33 -> 1.0 with pre==thr every frame -- the value arrives via
the ENGINE push through the streamed .CTL binding, not the bridge -- and
speedDemand=61.501 comes out of the authentic InterpretControls.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Cyd
2026-07-17 22:14:37 -05:00
co-authored by Claude Fable 5
parent ac57a474ef
commit 9f35a8034a
3 changed files with 46 additions and 2 deletions
+23
View File
@@ -1174,6 +1174,29 @@ void
}
//
//############################################################################
// Game-side device query (glass-cockpit step 2c): True when a real cockpit
// device (serial RIO on the pod, PadRIO under BT_GLASS) is present AND
// delivering input. The game's dev keyboard input bridges (mech4.cpp,
// mechmppr.cpp) stand down then -- they would clobber the device's engine
// push every frame. This automates the documented pod intent
// ("BT_KEY_BRIDGE=0 to disable on pods").
//############################################################################
//
int
BTRIODevicePresent(void)
{
if (application == NULL)
{
return 0;
}
LBE4ControlsManager *controls =
(LBE4ControlsManager *)application->GetControlsManager();
return controls != NULL
&& controls->rioPointer != NULL
&& controls->rioPointer->IsOperational();
}
//############################################################################
// Execute
//