Click or drag to resize

ReInputControllerHelperSetUnityJoystickIdFromAnyButtonPress Method

Sets a Unity joystick as the input source of a Joystick. The first Unity joystick that returns a button press will be assigned to the Joystick. While no buttons are pressed, this will return False. When a button press is detected, it will return True and assign the joystick id.

Namespace:  Rewired
Assembly:  Rewired_Core (in Rewired_Core.dll) Version: (
public bool SetUnityJoystickIdFromAnyButtonPress(
	int joystickId


Type: SystemInt32
The id of the Joystick

Return Value

Type: Boolean
True if a joystick button was pressed and a joystick id was assigned.
See Also