Available since LÖVE 0.9.0
This function is not supported in earlier versions.
Gets the button, axis or hat that a virtual gamepad input is bound to.
inputtype, inputindex, hatdirection = Joystick:getGamepadMapping( axis )
GamepadAxis axis
JoystickInputType inputtype
number inputindex
JoystickHat hatdirection (nil)
Returns nil if the Joystick isn't recognized as a gamepad or the virtual gamepad axis is not bound to a Joystick input.
inputtype, inputindex, hatdirection = Joystick:getGamepadMapping( button )
GamepadButton button
JoystickInputType inputtype
number inputindex
JoystickHat hatdirection (nil)
Returns nil if the Joystick isn't recognized as a gamepad or the virtual gamepad button is not bound to a Joystick input.
The physical locations for the virtual gamepad axes and buttons correspond as closely as possible to the layout of a standard Xbox 360 controller.
© 2006–2016 LÖVE Development Team
Licensed under the GNU Free Documentation License, Version 1.3.
https://love2d.org/wiki/Joystick:getGamepadMapping