fix: deliver AutoA taps to the first connected gamepad #318
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/318"
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 LooperSalty/AnyXboxX. Originally posted by mauroalvare on 2026-11-26T02:44:27Z.
Change
anyxboxx run --auto-apassesVICTORY_AUTO_A=150to Neptune. On the base commit, GameInput synthesized Enter for the keyboard and its stand-in gamepad. Connecting an XInput pad disconnects the stand-in, leaving the title's gamepad reads without the automatic A pulse.Sample the pulse through
Source::auto_aand add A to the lowest-numbered connected XInput pad. Physical buttons, triggers and axes are included in that reading. With no XInput pad, the stand-in receives the tap through Enter. Microsoft XInput controller indicesOriginal verification
Base
c4c93bdc413191a9dc909998d2d53080a3f0c880, head8630cac. Windows PowerShell 5.1, Rust 1.98.1 and Python 3.13.15.The full Python suite used the RTX 5070 Ti (driver 621.40) for hardware tests and WARP for explicit software-adapter checks. C++ runtime, Rust bridge and TomBox binaries were reused from identical source trees and submodule commit. The launcher and GameInput reproductions ran on the CPU.
Oracle and test data
The launcher's existing synthetic executable prints its environment. The release launcher test checks that the child receives
VICTORY_AUTO_A=150. The Rust test uses synthetic XInput slots 1 and 3 and reads the state through the title-facing GameInput methods. Slot 1 reported B alone (0x8) on the base and A+B (0xC) with the fix. The test also checks the analog values, the other pad, and the end of the pulse while Enter is held.Checklist
hle-probefixture.Investigation, implementation and verification were assisted by OpenAI Codex.
Rebase verification
Rebased on
c41c224.cargo test --locked --offline -j 4 -p victory-hle gameinput -- --test-threads=1passed all 8 GameInput tests.python -m pytest -q -rs tests/test_lanceur_victory.py tests/test_anyxboxx_run.pypassed all 28 tests with the release launcher.Imported from LooperSalty/AnyXboxX. Originally posted by Exorion1er on 2026-11-26T11:04:08Z.
Review: APPROVED
Thanks! AutoA was already on main (Neptune's
start-neptune.ps1and the launcher's-AutoAswitch), so this fixes an existing opt-in path rather than adding behaviour: withVICTORY_AUTO_Aunset nothing changes. The regression test reproduces the missing tap with a pad in slot 1, and the fix stays inside the GameInput poll. Small non-blocking nit: the auto-A flag riding onSource::keys()as a tuple could be its own trait method. Approving.Imported from LooperSalty/AnyXboxX. Originally posted by LooperSalty on 2026-11-26T14:01:35Z.
This PR now conflicts with main in
tests/test_lanceur_victory.py(other launcher PRs changed the same test module). Please rebase on main, keep the tests of both sides, runpython -m pytest tests/test_lanceur_victory.pyand force-push your branch.🤖 Generated with Claude Code
Imported from LooperSalty/AnyXboxX. Originally posted by mauroalvare on 2026-11-26T18:25:28Z.
I rebased the GameInput fix and took the suggestion to expose the tap through a separate
Source::auto_amethod. The poll samples it once for the keyboard and the first connected controller. The release-launcher test now coversanyxboxx run --auto-a.All eight GameInput tests and all 28 launcher tests passed.
The latest CI run passed.
Imported from LooperSalty/AnyXboxX. Originally posted by mauroalvare on 2026-11-27T00:49:27Z.
Updated this branch for the mouse support added by #461. Auto-A still taps the first connected pad, and mouse input still reaches the stand-in pad. All 21 automatic GameInput tests passed, including a new regression that exercises Auto-A and the mouse together.
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.