gameinput: auto-drive right stick from mouse when LOOK_PULL is idle (minigames) #525
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
hle
input
INTEL
lighting
linux-proton
memory
MULDER
needs-info
needs-logs
needs-rebase
NVIDIA
performance
post-merge
pr-diagnostics
pr-docs
pre-merge
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
relevance
high
relevance
low
relevance
medium
relevance
very-high
rendering
report
roadmap-proposal
saves
series-s
shaders
startup
status
blocked-by-rework
status
needs-test-report
status
needs-triage
status
ready-for-review
status
stale
status
superseded
status
wip
tools
ui
upstream
wontfix
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
TrustNo1/Darner!525
Loading…
Reference in a new issue
No description provided.
Delete branch "aowu/Darner:pr/minigame-mouse-right-stick"
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?
Problem
In native 1:1 mouse mode, camera look is injected via
mousehook'sLOOK_PULLhook. During minigames that read the right stick directly instead of running normal camera updates (such as lockpicking, safe dials, hotwiring, or object inspection),LOOK_PULLstops running, so moving the mouse has no effect and players have to fall back to keyboard keys.Fix
gameinput::note_look_pull()) wheneverlook_entered/look_returnedruns.LOOK_PULLhas been idle for>= 200 ms, consume raw mouse deltas (RAW_DX/RAW_DY) through a smoothedIdleRightStickmapper (right_x/right_y, honoringDARNER_MOUSE_INVERT_Yand decaying cleanly to zero after 50 ms without motion).IDLE_RIGHT_STICKimmediately wheneverLOOK_PULLresumes or when entering F1 menu, Pause menu, Map, or radial wheel.Verification
idle_look_pull_drives_right_stick_and_decays.cargo test -p darner-hle --lib gameinputpasses (117/117).#429 (draft, waiting on #364) covers the same minigames with explicit hold keys, so I read the two together. Two things came up, from the code only (I haven't run this branch):
RAW_DX/RAW_DYinoverlay(), which runs beforepoll(). While a #429 hold key is down,poll()swaps the same counters to move the held stick or trigger. In a minigame (LOOK_PULLidle) the idle path would take the counts first, so the held control would not move, and the result is merged withfurther()anyway. Proposed fix: the idle path stands down while a hold key is down (with #429 merged that isHOLDING.load(Ordering::Relaxed); I can add that guard on #429's side if this lands first).So I see them as complementary: this one needs no key for right-stick-only minigames, and #429 is for the ones that need a stick held at a point, two sticks, or a trigger part way. Only item 1 needs a change.
@EmberReD Thanks for taking the time to read through this and check how it interacts with #429!
Completely agree on both points — zero-key automatic right-stick rotation for dial/lockpicking minigames and #429's explicit hold-key positioning for two-stick / held-angle / partial-trigger minigames (like hotwiring) complement each other nicely.
Happy to coordinate on the
RAW_DX/RAW_DYguard whichever lands first: if #429 merges first, I'll rebase and add theHOLDINGstand-down check here; if #525 lands first, adding it on #429's side sounds great!Test needed — commit
8c292969; what to check: the change described aboveEvidence to post: card + driver, settings, commit tested, before/after (switch off vs on, two runs each), fps median and p99, and one line saying you looked at the picture.
Reply
testingto take this run; it's free again after 24 h with no results.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.