diff --git a/src/hook.cpp b/src/hook.cpp index f41355a..8d21116 100644 --- a/src/hook.cpp +++ b/src/hook.cpp @@ -291,9 +291,14 @@ static int _cdecl _GetMouseState(Mouse* pMouse) if (DIMOUSE->GetDeviceState(sizeof(Mouse), pMouse) < 0) { - while (DIMOUSE->Acquire() == DIERR_NOTINITIALIZED); + if (DIMOUSE->Acquire() == DIERR_NOTINITIALIZED) + { + while (DIMOUSE->Acquire() == DIERR_NOTINITIALIZED); + } } + pMouse->wheelDelta = mouseInfo.wheelDelta; + mouseInfo.wheelDelta = 0; pMouse->buttons[0] = (GetAsyncKeyState(1) >> 8); pMouse->buttons[1] = (GetAsyncKeyState(2) >> 8); pMouse->buttons[2] = (GetAsyncKeyState(4) >> 8); diff --git a/tools/premake5.lua b/tools/premake5.lua index 8d9376f..482bdf1 100644 --- a/tools/premake5.lua +++ b/tools/premake5.lua @@ -5,8 +5,8 @@ -- Environment vars PSDK_DIR = os.getenv("PLUGIN_SDK_DIR") DX9SDK_DIR = os.getenv("DIRECTX9_SDK_DIR") -GTASA_DIR = "C:/Work/GTASanAndreas" -GTAVC_DIR = "F:/GTA Vice City" +GTASA_DIR = "F:/GTASanAndreas" +GTAVC_DIR = "E:/GTA Vice City" if (DX9SDK_DIR == nil) then error("DIRECTX9_SDK_DIR environment variable not set")