GameInput: keep the keyboard stand-in for idle pads #3755
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3755"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T15:20:09Z.
The keyboard stand-in disappears when a host pad supplies its first non-default reading. A resting stick or trigger can produce a small nonzero reading. At initial activation, require a button, a trigger above the XInput threshold, or a stick outside XInput's circular deadzone. An activated pad forwards its original readings until it disconnects. XInput deadzone guidance
The generated-input regression fails on main because the resting pad takes the real slot. With this change the keyboard still drives the stand-in. A diagonal stick movement activates the pad, subsequent small values reach the pad reading, reconnecting at rest brings back the keyboard, and an above-threshold trigger can activate the new connection.
All 11 GameInput tests passed in both ordinary and diagnostic builds. Both strict HLE Clippy configurations and the asset policy passed.
Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T15:24:36Z.
Windows CI passed on
08edf43, including both Clippy configurations and the workspace tests. The same generated-input test failed onmain, where a resting pad immediately took the real slot. The patch kept the keyboard available during drift and forwarded the physical readings after a deliberate movement. All 11 GameInput tests passed locally in both normal and diagnostic configurations.The next step is maintainer review. Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by cloph-dsp on 2026-11-28T15:36:27Z.
Independent local verification (Windows, Rust 1.100.0/MSVC, no game data):
08edf4316ebda3e377e344ec0d321ef76d06bb3e, base/parent63bcca43c6a00a758510398fa43096ce7e4f7df0.cargo test --locked -p victory-hle --lib -- modules::gameinput::tests::idle_analog_input_keeps_the_keyboard_stand_in --exact --test-threads=1 --quiet→ 1 passed, 0 failed, 152 filtered, exit 0.git grep -Ffor the test name on the parent returned no match (test is new on this PR);git diff --check HEAD^ HEADclean (1 file, +87/-3).CARGO_TARGET_DIR(never shared) withCARGO_BUILD_JOBS=2.AI-assisted (Hy4 flash).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.