Implement held ADV fast-forward input

This commit is contained in:
gamer147
2026-07-21 10:45:46 -04:00
parent f840e356cf
commit c6b4985984
9 changed files with 167 additions and 17 deletions

View File

@@ -2292,6 +2292,12 @@ poll/dispatch ops `0xff` and `0x100`. These calls are effectful engine configura
`input_poll_joystick_action_bits@0x460380`. The first three logical actions are therefore not a generic
Godot UI ordering; they are the native engine ABI established by the input manager and refined by scripts.
The same mask is also consumed directly by `adv_interpreter_tick@0x410fb0`. Logical action 6 is bit
`0x40`, the exact bit used by the transient ADV fast-forward/run-state path. There is no Ctrl-specific
branch: SYSTEM4's C and LeftCtrl mappings, the retained native Backspace default, and any joystick mapping
that emits action 6 all reach the same hold-to-fast-forward mechanism. Persistent op-`0x88` Skip injects
that same bit independently each tick.
The port now models this as one process-owned `InputBindings` service. It starts with the native seven
keyboard defaults, the four configuration handlers mutate it, and `0xff` combines live keyboard-VK,
left/right mouse, joystick-axis, and joystick-button state with the narrow logical injection used by tests.
@@ -2300,8 +2306,10 @@ uses callback slot `count` only for an empty mask. Godot translates layout-indep
native Win32 VK namespace and sends physical mouse/standard joy events through the service; it no longer
assigns Godot's `ui_*` actions directly to AGE indices. Direct-scene diagnostics replay the same 16 immediate
SYSTEM4 configuration calls through `InputBindingBootstrap`, while natural boot executes the real opcodes.
This remains frontend input configuration only: it needs no profile storage, boot seed, or game-specific
conditional.
The live action-6 state now also feeds the ADV fast-forward host channel while the ADV lifecycle service is
enabled. That transient channel is kept separate from persistent op-`0x88` Skip, so releasing the held key
cannot clear the user's toggle; both channels share the existing text completion, wait advance, voice
deferral, and skip cadence. This needs no profile storage, boot seed, or game-specific conditional.
---

View File

@@ -824,7 +824,7 @@ op 0x90 (u0041BEB0, argc 7): `0x90 x y w h tgt_a tgt_b tgt_c`. Kelebek left it "
- **summary:** (out) - write 1 iff ADV message-skip run-state bit 0x08000000 is set, otherwise 0.
- **grounding:** source=investigation, confidence=high
- **depended on by:** 0x20c, 0x20d, 0x21c, 0x223
- **evidence:** Ghidra handler 0x4272b0 reads ctx+0xa0ce4 bit 0x08000000 and vm_operand_write(1, 1|0). SC0000 label_1235a ORs it with op 0x1cc.
- **evidence:** Ghidra /v2: handler 0x4272b0 reads ctx+0xa0ce4 bit 0x08000000 and vm_operand_write(1, 1|0). adv_interpreter_tick@0x410fb0 first polls the configured logical-action mask; action 6 is bit 0x40 and therefore drives this transient run state from SYSTEM4's C/LeftCtrl bindings or the retained native Backspace default. Persistent op-0x88 state injects the same bit. SC0000 label_1235a ORs the result with op 0x1cc.
### 0x1ca `set-read-message-skip` (u0041B9B0, argc 1)
- **summary:** (enabled) - set the engine setting `message:ReadTextSkip`, which skips only previously read text.

View File

@@ -2190,3 +2190,19 @@ empty-mask dispatch, simultaneous/bounded actions, and native range failures.
**Next:** manually exercise TITLE, ROOM, and ADV with keyboard, left/right mouse, and—if available—a
controller. A clean check should confirm native direction order, Z/Enter/Space behavior, right-click action
7, and release re-arming before selecting another reached Phase-B cluster.
### Slice B1 ADV held fast-forward implemented (2026-07-21)
Manual validation found the general input bindings sound but LeftCtrl did not accelerate ADV. Native tracing
resolves the missing consumer: `adv_interpreter_tick@0x410fb0` polls the configured logical mask and uses
action 6's bit `0x40` for transient fast-forward. It does not test Ctrl directly, so SYSTEM4's C/LeftCtrl
bindings and the engine's retained Backspace default intentionally share the behavior.
The VM now forwards held action 6 through an ADV-lifecycle-gated physical skip channel. Godot combines it
with, but stores it separately from, persistent op-`0x88` Skip; release therefore restores normal playback
only when the persistent channel is also off. The combined state reuses text completion, wait advance,
voice deferral/release, and skip pacing. Focused tests cover Backspace/C/Ctrl, activation on ADV resume, and
persistent-toggle survival across a physical press/release.
**Next:** manually hold LeftCtrl through text reveal and multiple waits in SC0000, then confirm release
returns to normal cadence and that the on-screen Skip toggle remains active if enabled during the test.