Fix showMouse hook
This commit is contained in:
parent
481c4c5ef4
commit
b6c0fe457f
@ -1,5 +1,8 @@
|
|||||||
#include "helpers.h"
|
#include "helpers.h"
|
||||||
|
|
||||||
|
// force show cursor
|
||||||
|
HOOK_DYNAMIC (i32, __stdcall, ShowMouse, i32 show) { return originalShowMouse (true); }
|
||||||
|
|
||||||
// xinput stuff
|
// xinput stuff
|
||||||
HOOK_DYNAMIC (u32, __stdcall, XinputGetState, u32 index, void *state) { return ERROR_DEVICE_NOT_CONNECTED; }
|
HOOK_DYNAMIC (u32, __stdcall, XinputGetState, u32 index, void *state) { return ERROR_DEVICE_NOT_CONNECTED; }
|
||||||
HOOK_DYNAMIC (u32, __stdcall, XinputSetState, u32 index, void *state) { return ERROR_DEVICE_NOT_CONNECTED; }
|
HOOK_DYNAMIC (u32, __stdcall, XinputSetState, u32 index, void *state) { return ERROR_DEVICE_NOT_CONNECTED; }
|
||||||
@ -54,6 +57,7 @@ HOOK_DYNAMIC (i64, __fastcall, UsbFinderGetSerialNumber, i32 a1, i64 a2) { retur
|
|||||||
|
|
||||||
void
|
void
|
||||||
init_boilerplate () {
|
init_boilerplate () {
|
||||||
|
INSTALL_HOOK_DYNAMIC (ShowMouse, PROC_ADDRESS ("user32.dll", "ShowCursor"));
|
||||||
INSTALL_HOOK_DYNAMIC (XinputGetState, PROC_ADDRESS ("xinput9_1_0.dll", "XInputGetState"));
|
INSTALL_HOOK_DYNAMIC (XinputGetState, PROC_ADDRESS ("xinput9_1_0.dll", "XInputGetState"));
|
||||||
INSTALL_HOOK_DYNAMIC (XinputSetState, PROC_ADDRESS ("xinput9_1_0.dll", "XInputSetState"));
|
INSTALL_HOOK_DYNAMIC (XinputSetState, PROC_ADDRESS ("xinput9_1_0.dll", "XInputSetState"));
|
||||||
INSTALL_HOOK_DYNAMIC (XinputGetCapabilites, PROC_ADDRESS ("xinput9_1_0.dll", "XInputGetCapabilities"));
|
INSTALL_HOOK_DYNAMIC (XinputGetCapabilites, PROC_ADDRESS ("xinput9_1_0.dll", "XInputGetCapabilities"));
|
||||||
|
@ -2,9 +2,6 @@
|
|||||||
#include "helpers.h"
|
#include "helpers.h"
|
||||||
#include "poll.h"
|
#include "poll.h"
|
||||||
|
|
||||||
// force show cursor
|
|
||||||
HOOK_DYNAMIC (i32, __stdcall, ShowMouse, i32 show) { return originalShowMouse (true); }
|
|
||||||
|
|
||||||
bool testEnabled = false;
|
bool testEnabled = false;
|
||||||
u16 drumMax = 0xFFFF;
|
u16 drumMax = 0xFFFF;
|
||||||
u16 drumMin = 0xFFFF;
|
u16 drumMin = 0xFFFF;
|
||||||
@ -12,16 +9,16 @@ u16 drumMin = 0xFFFF;
|
|||||||
#define ON_HIT(bind) IsButtonTapped (bind) ? drumMax == drumMin ? drumMax : (u16)(rand () % drumMax + drumMin) : 0
|
#define ON_HIT(bind) IsButtonTapped (bind) ? drumMax == drumMin ? drumMax : (u16)(rand () % drumMax + drumMin) : 0
|
||||||
|
|
||||||
Keybindings EXIT = { .keycodes = { VK_ESCAPE } };
|
Keybindings EXIT = { .keycodes = { VK_ESCAPE } };
|
||||||
Keybindings COIN_ADD = { .keycodes = { VK_RETURN }, .buttons = { SDL_CONTROLLER_BUTTON_START } };
|
|
||||||
Keybindings TEST = { .keycodes = { VK_F1 } };
|
Keybindings TEST = { .keycodes = { VK_F1 } };
|
||||||
Keybindings SERVICE = { .keycodes = { VK_F2 } };
|
Keybindings SERVICE = { .keycodes = { VK_F2 } };
|
||||||
Keybindings DEBUG_UP = { .keycodes = { VK_UP } };
|
Keybindings DEBUG_UP = { .keycodes = { VK_UP } };
|
||||||
Keybindings DEBUG_DOWN = { .keycodes = { VK_DOWN } };
|
Keybindings DEBUG_DOWN = { .keycodes = { VK_DOWN } };
|
||||||
Keybindings DEBUG_ENTER = { .keycodes = { VK_RETURN } };
|
Keybindings DEBUG_ENTER = { .keycodes = { VK_RETURN } };
|
||||||
Keybindings P1_LEFT_BLUE = { .keycodes = { 'D' } };
|
Keybindings COIN_ADD = { .keycodes = { VK_RETURN }, .buttons = { SDL_CONTROLLER_BUTTON_START } };
|
||||||
Keybindings P1_LEFT_RED = { .keycodes = { 'F' } };
|
Keybindings P1_LEFT_BLUE = { .keycodes = { 'D' }, .axis = { SDL_AXIS_LTRIGGER_DOWN } };
|
||||||
Keybindings P1_RIGHT_RED = { .keycodes = { 'J' } };
|
Keybindings P1_LEFT_RED = { .keycodes = { 'F' }, .buttons = { SDL_CONTROLLER_BUTTON_LEFTSTICK } };
|
||||||
Keybindings P1_RIGHT_BLUE = { .keycodes = { 'K' } };
|
Keybindings P1_RIGHT_RED = { .keycodes = { 'J' }, .buttons = { SDL_CONTROLLER_BUTTON_RIGHTSTICK } };
|
||||||
|
Keybindings P1_RIGHT_BLUE = { .keycodes = { 'K' }, .axis = { SDL_AXIS_RTRIGGER_DOWN } };
|
||||||
Keybindings P2_LEFT_BLUE = {};
|
Keybindings P2_LEFT_BLUE = {};
|
||||||
Keybindings P2_LEFT_RED = {};
|
Keybindings P2_LEFT_RED = {};
|
||||||
Keybindings P2_RIGHT_RED = {};
|
Keybindings P2_RIGHT_RED = {};
|
||||||
|
Loading…
Reference in New Issue
Block a user