-
Notifications
You must be signed in to change notification settings - Fork 7
XInput
This information is referenced in
- http://forums.steampowered.com/forums/showthread.php?t=1288744
- http://forums.anandtech.com/showthread.php?t=2230961
- http://answers.microsoft.com/en-us/windows/forum/windows_xp-gaming/how-to-disable-force-feedback-in-xbox-360-wireless/6e1e6c86-ee6d-e011-8dfc-68b599b31bf5
The folder in the topic Home > Files contain these files that's patched with the .dif in this repo
file bit original patched
xinput1_3.dll 32 39d5bf9b 6217d796
XInput9_1_0.dll 64 df3d276d 9f533f12
XInput9_1_0.dll 32 aeb3b49e 34b7de83
The column names mean
- file: filename
- bit: bit length
- original: CRC32 of the original file
- patched: CRC32 of the patched file
If the game exe is 32 (rather than 64) bit read "System32" as "SysWOW64" in this topic
Use the patched xinput*.dll instead of %WinDir%\System32\xinput*.dll by
-
placing it in the same folder as the game exe (f.e. Blur.exe)
-
placing it in a %PATH% folder with higher priority than %WinDir%\System32
-
overwriting %WinDir%\System32\xinput*.dll
The purpose of the xinput*.dll patches is
- disable vibration
This is useful because
-
the Xbox gamepad software don't have an option to disable vibration
-
the games in the topic "Games" don't have an option to disable vibration
-
for users that never use vibration it's easier than disabling vibration in the game
These games don't have an option to disable vibration
- Blur
- Need for Speed Rivals
The patches are created in IDA with
- IDA View: find a patch location
- Hex View: placed next to IDA View to show the instruction data that should be changed
- Edit > Patch program: change code
- Produce file > Create DIF file...: create .dif file that can be used with idadif.py to apply the change
The XInput9_1_0.dll patch is tested with the 2010-06 RumbleController DirectX SDK sample build with 7.1\Lib\x64\Xinput.lib from the Windows SDK because despite
#define XINPUT_USE_9_1_0
at the start of RumbleController.cpp the DirectX SDK Xinput.lib use xinput1_3.dll rather than XInput9_1_0.dll
Vibration is enabled by calling
DWORD __stdcall XInputSetState(DWORD dwUserIndex, XINPUT_VIBRATION *pVibration)
This jump if vibration should be enabled
loc_402CCC:
cmp dword ptr [ebp+pVibration], 0
jnz short loc_402D1B
Removing the jump mean that vibration is never enabled
This jump if vibration should be enabled
loc_7FF24E41E3C:
cmp [rsp+58h+arg_8], 0
jnz short loc_7FF24E41EAC
This jump if vibration should be enabled
loc_10001B33:
cmp dword ptr [ebp+pVibration], 0
jnz short loc_10001B94