From d4b80ac48de2c58fb89cd6639227d0eee4e13bdf Mon Sep 17 00:00:00 2001 From: FunkyFr3sh Date: Sun, 20 Aug 2023 17:54:06 +0200 Subject: [PATCH] don't hook DirectInputCreateW --- src/hook.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/hook.c b/src/hook.c index b7a06df..a0c9b3e 100644 --- a/src/hook.c +++ b/src/hook.c @@ -105,7 +105,7 @@ HOOKLIST g_hook_hooklist[] = "dinput.dll", { { "DirectInputCreateA", (PROC)fake_DirectInputCreateA, (PROC*)&real_DirectInputCreateA, SKIP_HOOK2 }, - { "DirectInputCreateW", (PROC)fake_DirectInputCreateW, (PROC*)&real_DirectInputCreateW, SKIP_HOOK2 }, + //{ "DirectInputCreateW", (PROC)fake_DirectInputCreateW, (PROC*)&real_DirectInputCreateW, SKIP_HOOK2 }, { "DirectInputCreateEx", (PROC)fake_DirectInputCreateEx, (PROC*)&real_DirectInputCreateEx, SKIP_HOOK2 }, { "", NULL, NULL, 0 } } @@ -573,6 +573,11 @@ void hook_init(BOOL initial_hook) /* Switch to 3 if we can be sure that ddraw.dll will not be unloaded from the process */ g_hook_method = 3; } + + if (g_hook_method == 2) + { + //dinput_hook_init(); + } } if (!g_hook_active || g_hook_method == 3 || g_hook_method == 4)