diff options
author | davidebeatrici <davidebeatrici@gmail.com> | 2016-06-24 00:32:22 +0300 |
---|---|---|
committer | Mikkel Krautz <mikkel@krautz.dk> | 2016-06-24 00:32:37 +0300 |
commit | ed8748dc07536c2ca67f2e803bf183c20826ee42 (patch) | |
tree | 5d75edf1cccafdd15b96a9b4bbc9ad358a2c295f /plugins/ut2004 | |
parent | 51af7852474d92a7d0514a0f57903551c3595f97 (diff) |
plugins: update memory addresses retrieval to use procptr32_t/procptr64_t.
Diffstat (limited to 'plugins/ut2004')
-rw-r--r-- | plugins/ut2004/ut2004.cpp | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/plugins/ut2004/ut2004.cpp b/plugins/ut2004/ut2004.cpp index d333dba18..e136ad729 100644 --- a/plugins/ut2004/ut2004.cpp +++ b/plugins/ut2004/ut2004.cpp @@ -35,15 +35,11 @@ */ //// -#include "../mumble_plugin_win32.h" +#include "../mumble_plugin_win32_x86.h" using namespace std; -BYTE *pos0ptr; -BYTE *pos1ptr; -BYTE *pos2ptr; -BYTE *faceptr; -BYTE *topptr; +procptr32_t pos0ptr, pos1ptr, pos2ptr, faceptr, topptr; static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, float *camera_pos, float *camera_front, float *camera_top, std::string &, std::wstring &) { //char ccontext[128]; @@ -103,10 +99,10 @@ static int trylock(const std::multimap<std::wstring, unsigned long long int> &pi if (! initialize(pids, L"UT2004.exe", L"Engine.dll")) return false; - BYTE *ptraddress = pModule + 0x4A44FC; - BYTE *ptr2 = peekProc<BYTE *>(ptraddress); - BYTE *ptr3 = peekProc<BYTE *>(ptr2 + 0xCC); - BYTE *baseptr = ptr3 + 0x1C8; + procptr32_t ptraddress = pModule + 0x4A44FC; + procptr32_t ptr2 = peekProc<procptr32_t>(ptraddress); + procptr32_t ptr3 = peekProc<procptr32_t>(ptr2 + 0xCC); + procptr32_t baseptr = ptr3 + 0x1C8; pos0ptr = baseptr; pos1ptr = baseptr + 0x4; |