Input: the mouse as the stand-in pad's camera (VICTORY_MOUSE) #1157
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!1157
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1157"
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?
@h0useadv on GitHub · 2026-11-24 16:18 UTC · original
h0useadv:input/mouse-camera→main· +175 −5 · 2 files · 1 commits · openThe keyboard's stand-in gamepad has no way to look around smoothly: I/J/K/L only give the right stick full deflection or none. This adds the mouse to that pad, opt-in.
What
VICTORY_MOUSE(1, or a sensitivity such as0.5or2; unset, empty or0is off). While the title's window has focus, the mouse adds to the stand-in pad:How
Source::mouse(), a default method returning no mouse, so the test fake and the non-Windows host are unchanged.with_mouse(pad, mouse), a pure function applied to the stand-in pad inState::poll.GetWindowRectof the focused window,GetCursorPos, thenSetCursorPosback to the centre; buttons throughGetAsyncKeyState(VK_LBUTTON,VK_RBUTTON). Onlywindows-sysfeatures the crate already enables.Tested
cargo test -p victory-hle --lib: 96 passed. Two new tests:with_mouse(adding, clamping, buttons, no mouse leaves the pad unchanged), and through the hub with the fake host (the mouse reaches the stand-in pad, and is gone once a real pad connects).cargo clippy -p victory-hle --all-targets: no warnings.cargo xtask policy: 154 files OK. rustfmt: the new code is formatted; the file's three existing rustfmt differences are untouched.VICTORY_MOUSE=1): focus on the title's window, cursor held exactly at its centre, menus at 30 fps; the cursor is free again once the title closes. I didn't get as far as a scene where the camera could be checked visually; the world doesn't render on my card yet.AI-assisted (Claude Code).
🤖 Generated with Claude Code
@Zipettte on GitHub · 2026-11-24 18:01 UTC · original
Tested on AMD Radeon RX 7700 XT (RDNA3, gfx1101), driver 32.0.32029.2010, Windows 11, Rust 1.98.1 MSVC at
d67e37d:cargo test -p victory-hlepasses, 97 passed / 0 failed. Workspace baseline on main (ffe310e) is green on the same machine (342 passed).Tested with AI assistance (Claude).
@Marvisak on GitHub · 2026-11-25 01:17 UTC · original
Automated triage for the maintainers.
Needs rebase. This pull request conflicts with
main(conflicting:crates/victory-hle/src/modules/gameinput.rs). It will be reviewed once it is rebased onto the currentmain.Generated by Claude Code
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.