There are many controllers assign the D-Pad based on Axis, which means we cannot use Input.Joystick0Button to map them. In this case, we need to tweak for settings.
Let me use an example to illustrate the situation. I am using Super Famicom controller (Switch edition) on Mac. Just simply connect it by Bluetooth menu, and I can use it in Unity already.
A little bit tricky is that inside Project Settings > Input Manager > Horizontal / Vertical, don’t forget to change Type to Joystick Axis, and select the correct axis!
For my controller, I need to select 11th axis for H and 12th for V.
Different controller might have different assignment, for example, PS4 Dual Shock should be 7th for H and 8th for V if I remember correctly.
1 Like
You set up a nintendo controller with Unity?
Yes, it works.