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.
  2. Dismiss Notice

Gamepad Mouse Cursor Sample straight up doesn't work on MacOS

Discussion in 'Input System' started by zephybite0, Sep 26, 2021.

  1. zephybite0

    zephybite0

    Joined:
    Apr 25, 2018
    Posts:
    29
    Hi, I've been trying to get Gamepad to be able to control mouse cursor, and tried my best to get the given "Gamepad Mouse Cursor" example to work, but it only works on Windows. On MacOS I can see in the Input Debugger that it changes the InputState mouse position values properly, but it doesn't trigger any events it seems, because buttons don't get highlighted and the InputAction "Point"'s performed event doesn't get called.

    I've tried using LTS Unity versions with different releases of the Input System package to no avail.

    Can someone give some insight into a solution for this? I found at least four different threads having the exact same problem with 0 replies.
     
  2. zephybite0

    zephybite0

    Joined:
    Apr 25, 2018
    Posts:
    29
    Ok I found the solution - I just updated to 1.1.1 Input System then used:

    Code (CSharp):
    1. InputSystem.QueueDeltaStateEvent(Mouse.current.position, newPos);
    instead of:

    Code (CSharp):
    1. InputState.Change(Mouse.current.position, newPos);
    Apparently there was a bug in the stable Input System version where Queueing State Events got dropped if in a InputAction callback context...........

    It would really be ideal if I didn't have to use the 1.1.0+ Input System though because I don't have faith in the non-stable Input System being less buggy than the stable version -.-

    And now I have a weird mouse Y axis getting inverted problem......
     
  3. snipeorigin

    snipeorigin

    Joined:
    Apr 3, 2014
    Posts:
    3
    Can confirm, it's not working and
    Code (CSharp):
    1. InputState.Change(Mouse.current.position, newPos);
    Isn't anywhere in my project to be found.
     
  4. MihaPro_CarX

    MihaPro_CarX

    Joined:
    Apr 5, 2017
    Posts:
    17
    I confirm that 1.1.1/Gamepad Mouse Cursor does not work and it is very frustrating when learning a new InputSystem.
     
    xor0 likes this.