From 9b6731de9a0980515d1d8954f46935a1445dcf02 Mon Sep 17 00:00:00 2001 From: uniboi <64006268+uniboi@users.noreply.github.com> Date: Sat, 21 Jan 2023 10:36:55 +0000 Subject: Expose Cursor Position to UI vm (#387) * add NSGetCursorPosition * fix vs filters * fix clang formatting * Create wininfo.h * Create wininfo.cpp * add wininfo to compiler options * add wininfo to filters * move wininfo * clamp position to screen size --- NorthstarDLL/util/wininfo.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 NorthstarDLL/util/wininfo.cpp (limited to 'NorthstarDLL/util/wininfo.cpp') diff --git a/NorthstarDLL/util/wininfo.cpp b/NorthstarDLL/util/wininfo.cpp new file mode 100644 index 00000000..991deb33 --- /dev/null +++ b/NorthstarDLL/util/wininfo.cpp @@ -0,0 +1,11 @@ +#include "pch.h" + +AUTOHOOK_INIT() + +HWND* g_gameHWND; +HMODULE g_NorthstarModule = 0; + +ON_DLL_LOAD("engine.dll", WinInfo, (CModule module)) +{ + g_gameHWND = module.Offset(0x7d88a0).As(); +} -- cgit v1.2.3