Getting the memory location was easy it's a simple 4 byte value but the game is 64bit so the address is a double word and is stored in a 64bit register (RCX). When I looked for what access the memory location I found it really quick and it looked like it would be a simple thing to add one line to the code to get me the address whenever I wanted.
So I tried the following:
Code: Select all
newmem:
mov [_basePtr],rcx //the code I added. Address I want is in RCX, so a simply copy to my variable
code:
mov eax,[rcx+000000C0]
jmp return
Code: Select all
newmem:
push rax //save what is in rax to stack
mov rax,rcx //copy address I want to rax register
mov [_basePtr],rax //copy rax value to my variable
pop rax //restore the original content of rax
code:
mov eax,[rcx+000000C0]
jmp return