Search Issue Tracker
By Design
Votes
0
Found in [Package]
1.1.1
Issue ID
ISXB-33
Regression
Yes
Virtual cursor does not follow actual cursor when using Input System
Reproduction steps:
1. Open the user's attached project
2. Make sure the reproducible version of the Input System package is installed on the project
3. Enter Play mode
4. Press ESC to open a custom menu and move the cursor around
Expected result: The virtual cursor follows the actual cursor
Actual result: The virtual cursor does not move
Reproducible with: 1.1.1 (2021.2.3f1), 1.2.0 (2022.1.0a15)
Not reproducible with: 1.0.2 - 1.1.0-pre.5 (2021.2.0f1)
Couldn't test with: 1.0.2 (2019.4.33f1, 2020.3.23f1) (Downgrading issues), 1.1.0-pre.6 (2021.2.0f1) (Package errors prevent reproduction)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- UI Builder can't set a background image to a sprite from a multi-sprite spritesheet in the Resources folder
- Light2D freeform does not render the internal part when rendered in certain shapes
- Using AddCopyPass causes an incorrect merging of passes.
- Negative Enum value is not pasted correctly when copying from another array
- Silent Crash when generating Lightmap UVs for a model with a large object scale
Resolution Note:
The virtual mouse in the repro project uses the MouseMove action to get delta values from the system mouse, but adding a virtual mouse device causes MouseMove to rebind to the virtual mouse delta as well, so mouse move now has two delta bindings. Subsequent calls to MouseMove.ReadValue() end up reading values from the virtual mouse instead of the system one, because it becomes the control driving the action when you first call InputState.Change(...). There are two solutions:
- Change the action type of the MouseMove action to passthrough. This will work but is really dependent on the order that the bindings are processed, so it's a bit brittle
- Read the mouse delta from the system mouse using Mouse.current.delta.ReadValue(), and pass that into the UpdateMotion method instead of reading it from the input action.