Unity 2019.1.0f2
Input System 1.0.2
- I create an empty 3D project, then import the Input System into it.
- I add EventSystem to the scene.
- Then I write a simple script and add it to scene:
using UnityEngine; using UnityEngine.InputSystem; public class TestScroll : MonoBehaviour { void Update() { Debug.Log(Mouse.current.scroll.ReadValue()); } }
- Then I run the scene and just move my mouse (don't spin the mouse wheel) and see this in the console:
Also in the documentation for the Input System I found this:
Because of this feature Scroll Rect starts to scroll simply because I move the mouse pointer over it.
How can this be avoided and why is this happening?