Input: the mouse as the stand-in pad's right stick and triggers, with a PC key layout (VICTORY_MOUSE=1, off by default) #1274
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1277"
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 fxceless/victory-fork. Originally posted by Livertea on 2026-11-26T09:17:28Z.
Ports avatarmanz/VIctory-7900XTX#153 (mavis140) — mouse-look — to victory-fork.
With no pad connected the keyboard is the title's pad and the camera sits on I/J/K/L, which makes a third-person title hard to steer. With
VICTORY_MOUSE=1the mouse becomes part of that stand-in pad: its travel is the right stick, its buttons are the triggers, and the keys are laid out after GTA V's keyboard and mouse controls (W A S D, Shift to sprint, Space, F, R, Q, Tab, Ctrl, C, V). Unset, nothing changes.What changed vs the original PR (adapted for victory-fork, which predates the
one_padrefactor)crates/victory-hle/src/modules/gameinput.rsLook: mouse travel paid out as a stick deflection over 45 ms, so a whole movement arrives and the stick comes to rest (VICTORY_MOUSE_SPEED, default 1400 px/s for a full stick;VICTORY_MOUSE_DEAD, default 0.12).MOUSE_BUTTONS: the second key table (Shift A, Space X, F Y, R B, Tab / Q shoulders, Ctrl / C stick clicks, V View, Esc / P Menu), used only with the switch on.one_padhere: victory-fork has noone_padmachinery, so the mouse feeds the existingfallback()path (used when no pad is connected) instead of the merged pad. Thea_host_pad_feeds_the_one_pad_which_never_goestest is dropped — it needsfake_with(bool), which doesn't exist here.crates/victory-hle/src/modules/lifecycle.rs: no pointer over the picture while the mouse is held (WM_SETCURSORin the window procedure that is already hooked).docs/README-fxceless.mdwas deleted in victory-fork's HEAD, so there's no docs file to add the key table to.Tested
cargo test -p victory-hle --lockedon victory-fork main atf6a09d3: 105 passed, 1 failed. All 3 mouse tests pass (right stick/triggers, driving pedals, travel payout), and all 10 gameinput tests pass. The one failure ismodules::display::tests::sdr_and_display_deferrals— a display test in a file this PR doesn't touch (HRESULT 0x800700AA, resource in use); pre-existing/environmental, not from this change.AI use
Written with Jimbob (Meta Muse): the port, the tests, and this description.
🤖 Generated with Jimbob
Pull request closed