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/codmw2 | |
parent | 51af7852474d92a7d0514a0f57903551c3595f97 (diff) |
plugins: update memory addresses retrieval to use procptr32_t/procptr64_t.
Diffstat (limited to 'plugins/codmw2')
-rw-r--r-- | plugins/codmw2/codmw2.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/plugins/codmw2/codmw2.cpp b/plugins/codmw2/codmw2.cpp index 2a7a9bd3f..a0b1e2271 100644 --- a/plugins/codmw2/codmw2.cpp +++ b/plugins/codmw2/codmw2.cpp @@ -35,7 +35,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include "../mumble_plugin_win32.h" +#include "../mumble_plugin_win32_x86.h" 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 &) { float viewHor, viewVer; @@ -59,7 +59,7 @@ static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, floa 0x007F7A34 byte Magical state value */ - ok = peekProc((BYTE *) 0x007F8AB4, &state, 1); // Magical state value + ok = peekProc(0x007F8AB4, &state, 1); // Magical state value if (! ok) return false; /* @@ -74,11 +74,11 @@ static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, floa if (state != 1) return true; // This results in all vectors beeing zero which tells mumble to ignore them. - ok = peekProc((BYTE *) 0x008F1FF8, avatar_pos+2, 4) && //Z - peekProc((BYTE *) 0x008F1FFC, avatar_pos, 4) && //X - peekProc((BYTE *) 0x008F2000, avatar_pos+1, 4) && //Y - peekProc((BYTE *) 0x008F2008, &viewHor, 4) && //Hor - peekProc((BYTE *) 0x008F2004, &viewVer, 4); //Ver + ok = peekProc(0x008F1FF8, avatar_pos+2, 4) && //Z + peekProc(0x008F1FFC, avatar_pos, 4) && //X + peekProc(0x008F2000, avatar_pos+1, 4) && //Y + peekProc(0x008F2008, &viewHor, 4) && //Hor + peekProc(0x008F2004, &viewVer, 4); //Ver if (! ok) return false; @@ -101,15 +101,15 @@ static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, floa // Calculate view unit vector /* - Vertical view 0° when centered - 85° when looking down - 275° when looking up + Vertical view 0° when centered + 85° when looking down + 275° when looking up Decreasing when looking up. - Horizontal is 0° when facing North - 90° when facing West - 180° when facing South - 270° when facing East + Horizontal is 0° when facing North + 90° when facing West + 180° when facing South + 270° when facing East Increasing when turning left. */ viewVer *= static_cast<float>(M_PI / 180.0f); |