Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mumble-voip/mumble.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavide Beatrici <davidebeatrici@gmail.com>2016-10-31 16:24:25 +0300
committerDavide Beatrici <davidebeatrici@gmail.com>2016-10-31 16:24:25 +0300
commit921ee19e3abd24482921d85b38c0c4b3d0cbcffe (patch)
treec26e7b7720b7c16d7b0e7bcd14394da9f898841b /plugins/rl
parentca2fd07b90746a17dba13963f7bdd54812c5d016 (diff)
plugins: use the short form of peekProc
The short form of peekProc automatically uses the correct size for the target.
Diffstat (limited to 'plugins/rl')
-rw-r--r--plugins/rl/rl_linux.cpp10
-rw-r--r--plugins/rl/rl_win32.cpp10
2 files changed, 10 insertions, 10 deletions
diff --git a/plugins/rl/rl_linux.cpp b/plugins/rl/rl_linux.cpp
index ac241626f..df737a627 100644
--- a/plugins/rl/rl_linux.cpp
+++ b/plugins/rl/rl_linux.cpp
@@ -23,11 +23,11 @@ static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, floa
if (!avatar_offset) return false;
// Peekproc and assign game addresses to our containers, so we can retrieve positional data
- ok = peekProc(avatar_offset + 0x60, avatar_pos, 12) && // Avatar Position values (X, Y and Z).
- peekProc(pModule + 0x3021398, camera_pos, 12) && // Camera Position values (X, Y and Z).
- peekProc(avatar_offset + 0x6C, avatar_front, 12) && // Avatar Front values (X, Y and Z).
- peekProc(pModule + 0x3021380, camera_front, 12) && // Camera Front Vector values (X, Y and Z).
- peekProc(pModule + 0x302138C, camera_top, 12); // Camera Top Vector values (X, Y and Z).
+ ok = peekProc(avatar_offset + 0x60, avatar_pos) && // Avatar Position values (X, Y and Z).
+ peekProc(pModule + 0x3021398, camera_pos) && // Camera Position values (X, Y and Z).
+ peekProc(avatar_offset + 0x6C, avatar_front) && // Avatar Front values (X, Y and Z).
+ peekProc(pModule + 0x3021380, camera_front) && // Camera Front Vector values (X, Y and Z).
+ peekProc(pModule + 0x302138C, camera_top); // Camera Top Vector values (X, Y and Z).
// This prevents the plugin from linking to the game in case something goes wrong during values retrieval from memory addresses.
if (! ok)
diff --git a/plugins/rl/rl_win32.cpp b/plugins/rl/rl_win32.cpp
index f39da5ff3..a3259b22a 100644
--- a/plugins/rl/rl_win32.cpp
+++ b/plugins/rl/rl_win32.cpp
@@ -25,11 +25,11 @@ static int fetch(float *avatar_pos, float *avatar_front, float *avatar_top, floa
if (!avatar_offset) return false;
// Peekproc and assign game addresses to our containers, so we can retrieve positional data
- ok = peekProc(avatar_offset + 0x0, avatar_pos, 12) && // Avatar Position values (X, Y and Z).
- peekProc(pModule + 0x171ABF8, camera_pos, 12) && // Camera Position values (X, Y and Z).
- peekProc(avatar_offset + 0xC, avatar_front, 12) && // Avatar Front values (X, Y and Z).
- peekProc(pModule + 0x171ABE0, camera_front, 12) && // Camera Front Vector values (X, Y and Z).
- peekProc(pModule + 0x171ABEC, camera_top, 12); // Camera Top Vector values (X, Y and Z).
+ ok = peekProc(avatar_offset + 0x0, avatar_pos) && // Avatar Position values (X, Y and Z).
+ peekProc(pModule + 0x171ABF8, camera_pos) && // Camera Position values (X, Y and Z).
+ peekProc(avatar_offset + 0xC, avatar_front) && // Avatar Front values (X, Y and Z).
+ peekProc(pModule + 0x171ABE0, camera_front) && // Camera Front Vector values (X, Y and Z).
+ peekProc(pModule + 0x171ABEC, camera_top); // Camera Top Vector values (X, Y and Z).
// This prevents the plugin from linking to the game in case something goes wrong during values retrieval from memory addresses.
if (! ok)