Search Unity

Question Unity not picking up inputs from the D-pad.

Discussion in 'Input System' started by MachineHead, Mar 21, 2023.

  1. MachineHead

    MachineHead

    Joined:
    Jan 6, 2016
    Posts:
    30
    Im not using the new input manager and instead setting it up in an old fashion way for a quick simple test of an input, but i cant get any input for the dpad despite being able to set up the rest of the controller in the same way.

    I understand that the dpad is an axis and not a binary input. Even the forloop i used to detect and number all inputs showed all the other keys, but the dpad simply wont show.

    i used the code.
    public float dpadX;
    public float dpadY;

    void update{
    float dpadX = Input.GetAxis("DpadX");
    float dpadY = Input.GetAxis("DpadY");
    }

    i made the float public to see if there was any input, but it stays at 0.

    my input setting i believe are set correctly in the input mamager. i looked up the axis for the xbox controller, dpad is on the 6th and 7th axis.

    im at a loss and dont know why Unity is ignoring my dpad.
     
  2. MachineHead

    MachineHead

    Joined:
    Jan 6, 2016
    Posts:
    30
    Did more searching for my issue.
    Im using a legacy build of Unity and found a package called inControl on github.

    I can now use my dpad.

    Its asinine that it takes all this to get it to work. Unity also has issues with playstation controlers. I also have a 2022 build of unity and it ignores the ps4 and ps5 dpads, even with the new input manager. it wont listen to the inputs. Only the Xbox controller works.

    Whatever, i got what i wanted.