Skip to content

Getting Started

Samuel Grossman edited this page Jan 1, 2025 · 2 revisions

This page acts as a "quick start" guide for getting Xidi set up and running.

System Requirements

  • Windows 10 or 11. Older versions of Windows are not supported.

  • Visual C++ Runtime for Visual Studio 2022. If running a 64-bit operating system, install both the x86 and the x64 versions of this runtime, otherwise install just the x86 version.

Obtaining Binaries

Xidi binaries are available on its Releases page. Be sure to download the latest available version.

Running an Application

  1. Install one of the forms of Xidi into the same directory as the game executable.

  2. Optionally supply configuration settings to Xidi.

  3. Run the application.

Forms of Xidi

Xidi is available in multiple forms, each of which caters to a particular way in which games might communicate with game controllers. The following subsections describe each form of Xidi and how to install it.

DirectInput

Many games use the DirectInput API to communicate with various input devices, including game controllers. For such games, place either dinput8.dll or dinput.dll into the same directory as the game executable. The former is for games that use version 8 of DirectInput, and the latter is for games that use any older version.

WinMM

Some games make use of the legacy joystick API offered by the Windows multimedia library. To use Xidi with these games, place winmm.dll into the same directory as the game executable.

HookModule

It is not common for games to need the HookModule form of Xidi.

Some games and mods bypass the loading mechanism upon which Xidi's other forms rely. The result of doing so is that even following the directions above is insufficient for Xidi to work. Both DirectInput and WinMM forms of Xidi are potentially affected.

Installation Steps

Games that do not work with Xidi's other forms alone might work with the HookModule form of Xidi, which is a hook module intended to be loaded by Hookshot. To install the HookModule form of Xidi:

  1. Place either dinput8.dll, dinput.dll, or winmm.dll into the same directory as the game executable, as usual for the other forms of Xidi.
  2. Additionally place Xidi.HookModule.XX.dll into the same directory as the game executable.
  3. Download Hookshot version 1.2.0 or higher. Extract Hookshot.XX.exe and Hookshot.XX.dll into the same directory as the game executable.
  4. Run the game with Hookshot. The easiest way to do this is using the Hookshot Launcher, as follows, but there are other ways that are described in Hookshot's documentation. To use Hookshot Launcher:
    1. Rename the game executable by adding the text _HookshotLauncher_ to the beginning. For example, Game.exe would be renamed to _HookshotLauncher_Game.exe.
    2. From the downloaded Hookshot release, extract HookshotLauncher.XX.exe to the same directory as the game executable, then rename it to the original name of the game executable. Following the example above, this would mean renaming HookshotLauncher.XX.exe to Game.exe.
    3. Run the game as normal. Hookshot Launcher will take care of ensuring Hookshot loads the game correctly.

In all of the steps above, note that XX is either 32 or 64 depending on whether the game executable is 32-bit or 64-bit.

Technical Explanation

Certain games that use DirectInput do not directly load the DLL but rather use a Windows subsystem known as Component Object Model (COM) to request that the system figure out how to access DirectInput functionality. This makes use of information in the system registry which ends up pointing to the system-installed version of DirectInput. The HookModule form of Xidi intercepts one of the key functions offered by COM to ensure that requests for DirectInput objects go through Xidi.

WinMM games typically do not themselves intentionally bypass the default library loading mechanism. Nonetheless, this problem can arise when the DLL search path is programmatically altered or if the WinMM DLL is loaded using by some other mechanism like API sets. In both cases, the HookModule form of Xidi intercepts invocations of the system-supplied functions and redirects them to Xidi.