Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Bug [New Input System] Initial state for Mouse Position is 0 ?

Discussion in 'Input System' started by msh91, Apr 11, 2021.

  1. msh91


    Apr 22, 2017
    I'm using the new input system, and I have a component that inside Update is reading the mouse Position (using generated C# class):


    InputControls is the name of the variable (type is the generated input class)
    Game is the action map
    MousePos is the action.

    According to this:

    When action type is set to Value, the initial value should be set correctly.
    However when starting the game the value is always zero until the mouse is moved.

    Anyone knows any workaround for this?