Gamepad Integration
Hypewire comes with built-in gamepad integration, allowing you to trigger actions when you use your gamepad, or simulate gamepad inputs in reaction to other events. The latter requires the ViGEm controller emulation driver.
Hypewire's gamepad integration for Windows uses the builtin XInput system, which is compatible with a wide range of devices, up to 4 connected at a time.
Triggering Hypewire actions with a gamepad
The On gamepad button pressed and On gamepad button released nodes let you receive button presses from a gamepad:
These nodes allow you to select an input gamepad. These four options map to the "player LED" on an Xbox360 controller. Hypewire doesn't keep track of physical devices, so if you replace the gamepad on Player 1 with a different device, the node will react to the new device's inputs.
The Rumble gamepad node lets you trigger a gamepads rumble motors:
This works similarly to the button pressed nodes. You can select between the motors supported by the device and set the duration they will rumble for once triggered. The Test button will trigger the rumble as if the node was triggered.
Triggering virtual gamepad inputs with Hypewire
Hypewire can emulate a virtual gamepad to send button presses, trigger inputs and thumbstick movements to games and other applications.
Setup
The virtual gamepad feature requires the ViGEm controller emulation driver. Download the latest release from Github, install it and restart your machine. This driver allows Hypewire to create virtual gamepads that appear like real devices.
Once installed, enable the virtual gamepad in the gamepad preferences (File > Preferences > Gamepad). If Hypewire fails to connect, or gets stuck on the "Connecting..." text for more than a few seconds, make sure the driver is installed correctly and try rebooting your machine.
When enabled and connected you should see this screen:
The screen indicates which player the virtual gamepad is connected as, in this case Player 2. It also has an option for merging input, more on this later.
Note: the virtual gamepad will only be connected as long as it is enabled and Hypewire is running. Disabling it or closing Hypewire will "disconnect" the gamepad.
Usage
There are six nodes for virtual gamepad input, which all work similarly:
- Move gamepad thumb moves a thumbstick to a set position
- Press gamepad button presses a button
- Press gamepad trigger presses a trigger with a set strength
- Spam gamepad button repeatedly presses and un-presses a button in a random pattern
- Spam gamepad trigger repeatedly moves a trigger in a random pattern
- Wiggle gamepad thumb wiggles a thumbstick around in a random pattern
All of these nodes apply for a duration of time and then "release" the input to its default state.
Here is an example of configuring a Wiggle gamepad thumb node:
Only one gamepad is available, this is the virtual gamepad we set up earlier. It is not possible to simulate inputs on real, non-virtual gamepads.
Merging a real gamepad and a virtual gamepad
Often we want to add inputs to our real gamepad instead of simply simulating a second fake gamepad. While this isn't directly possible, Hypewire provides a workaround: repeating your real gamepad inputs as the virtual gamepad, so the virtual gamepad has a combination of your inputs and fake inputs triggered in Hypewire.
We can set this up in the gamepad preferences (File > Preferences > Gamepad). With the virtual gamepad enabled, select a real gamepad to merge inputs with. For example, with a real gamepad connected as Player 1 and a virtual gamepad connected as Player 2, this setting will repeat Player 1 inputs on Player 2:
Games and other apps will now see your real inputs from both Player 1 and 2, and fake inputs triggered in Hypewire from Player 2. Most games will require some adjustment to make this work properly.
- Some games allow you to select an input device. For these, select the device corresponding to the virtual gamepad.
- Some games only take inputs from the first connected device, or from Player 1. For these, make sure the virtual gamepad is enabled first before plugging in or turning on your controller. Alternatively, disable the virtual gamepad and disconnect your controller, then re-enable the virtual gamepad, then connect your controller. Make sure the virtual gamepad is listed as being connected as Player 1.
- Other games take inputs from all connected devices, leading to double-presses, missed presses, randomly enabling split-screen modes, etc. For these, you will need a separate tool to hide the real device from the game. See the next section.
Hiding a real gamepad when using merging
As noted above, some games and applications do not behave correctly with input merging enabled. To fix this, you can use a separate tool named HidHide to hide the real device from those games, so they only see the virtual gamepad.
The latest release of HidHide can be downloaded from Github. Once installed, make sure to restart your machine.
HidHide comes with a simple configuration tool. Once opened, switch to the "Devices" tab, and you should see something like this:
If you have Hypewire open with the virtual gamepad enabled, you will see it listed as well as an Xbox360 controller. For now it's best to close Hypewire and restart the configuration client so only real gamepads are listed here.
Click the checkbox to hide the device from all games, and then check "Enable device hiding" in the bottom left to enable HidHide. Re-connect your controller, it will now be hidden to all applications.
We still need to let Hypewire see the controller, otherwise it won't be able to merge inputs to your virtual gamepad.
To do this, switch to the "Applications" tab and add the Hypewire executable to the list - you can likely find it at
C:\Program Files\Hypewire\hypewire.exe
.
Your application list should look something like this:
Finally, re-connect your controller again, and start Hypewire. You should now be able to set up virtual gamepad merging with your real device in Hypewire, while other games and applications will only see the virtual gamepad.
For more information, see the HidHide setup guide.
Note: unlike the Hypewire virtual gamepad, your HidHide configuration will persist even when Hypewire or the HidHide configuration client is not running. To disable hiding, uncheck "Enable device hiding" in the Devices tab of the HidHide configuration client, or uninstall HidHide.