Testing Rewired Applications using GameDriver

Learn how to work with Unity applications using the Rewired Input System package with GameDriver

As with various Unity input systems, GameDriver can be used with a project using the Rewired input system. While sending input via GameDriver calls is similar to that of other XR input systems, some prerequisite configuration steps allow GameDriver to access the Rewired systems as needed.

All configuration steps can be done through the Rewired Editor, which should be accessible through the Rewired Initializer that most likely already exists in your scene if it has already been set up for use with Rewired. If not, it can be created via the Unity Editor by navigating to Window Rewired Create > Initializer.

Once the Rewired Editor has been opened, navigate to the "Custom Controllers" tab, as shown below:

Here you can create a new custom controller with both the Name and Descriptive Name of "GDIOController" (GDIOControllerX, where X is some integer, is also an acceptable name). After the controller or controllers have been made, you can add any axes and/or buttons that you would like to simulate.

Next, navigate to the "Players" tab. You then select the "Custom Controllers" button at the bottom of the window, which will then give you the option to add a custom controller.

Proceed to add all of the controllers defined in the first step, using the tag "GDIOController" for each of them.

Lastly, move to the "Custom Controller Maps" tab and select the custom controllers that you configured in the previous steps. From here you can either create new categories and layouts in order to define your own custom layouts specific to the GDIO controllers, as shown below, or you can use the Default mappings if you already have them bound to the preferred in-game events.

Also, note that the GDIOAgent must be configured to "Force Old Input System" when using the Rewired input system, as shown below.

Once everything above has been configured correctly, you should be able to send simulated input to the rewired controllers using the standard "DeviceName/ElementName" format, like in the following example:

api.ButtonPress(“GDIOController/RightTrigger”, 300, 1.0f)