-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathwrapper.d
More file actions
25 lines (22 loc) · 708 Bytes
/
wrapper.d
File metadata and controls
25 lines (22 loc) · 708 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
module wrapper;
export {
extern (Windows)
void* DirectInput8Create(void* hinst, uint dwVersion, void* riidltf, void** ppvOut, void* punkOuter)
{
asm {
naked;
jmp DirectInput8Create_Hook; // steam overlay compatibility
}
}
}
extern (Windows)
void* DirectInput8Create_Hook(void* hinst, uint dwVersion, void* riidltf, void** ppvOut, void* punkOuter)
{
if (!DirectInput8Create_Real)
return null;
return DirectInput8Create_Real(hinst, dwVersion, riidltf, ppvOut, punkOuter);
}
__gshared {
extern (Windows)
void* function(void* hinst, uint dwVersion, void* riidltf, void** ppvOut, void* punkOuter) DirectInput8Create_Real = null;
}