stride3d / stride3d/stride

Spaming Mouse Rigthclick moves mouse by (-1, -1) coordinates

Open
#1,935 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
C#
Stars
7.8k
Forks
1.2k
Avg merge
2d 17h
Merged PRs (30d)
49

Description

Release Type: Official Release
Version: 4.1.0.1948 (.NET 6.0.11)

Platform(s): Windows 10 Pro

Describe the bug
basically title, but i could narrow the problem down a bit futher.
I susspect
Input.LockMousePosition() OR Input.UnlockMousePosition()
to be the problem.

Found in BasicCameraController from the basic Scripts that one can make in the InEditor Assets.

Here are 2 gifs ( a shame i forgot to capture the coursor in this one!!):
rightClickSpam_Code

And here is one with faster spam and without breakpoints:
rightClickSpam

(as a bonus note: if one rightclicks on the maximum possible TOP position, the context of WindowsMS itself opens, moving focus away from the rendererWindow and freezing the mouse in place, only Escape can help here)

To Reproduce
Steps to reproduce the behavior:

  1. Empty project
  2. add the BasicCameraController from the basic Scripts that one can make in the InEditor Assets
  3. Add a Camera for main Slot

Expected behavior
Mouse should not be moved by the Script.

Screenshots
Gifs included above

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the BasicCameraController from the basic Scripts and inspect its use of Input.LockMousePosition() and Input.UnlockMousePosition(). Reproduce the issue in an empty project with a main-slot Camera by rapidly right-clicking, then verify that the mouse no longer moves by (-1, -1) and that the Windows context menu does not take focus.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
game-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.