Jump to content

Finding a process memory and reading data


Recommended Posts

After reading this very nice post about memory reading ( http://www.autoitscript.com/forum/index.php?showtopic=55095 ) I have a question.

Used Cheat Engine to find the pointer to the score variable and it returned:

;pinball + 25040 (offset 52)
;pinball + 25658 (offset 52)

;points to 00A90C62

Thus I somehow have to put this inside my code by translating "pinball" to some memory address.

How do I do that with autoit?

Here is my first attempt to mess with windows pinball which successfully changes the score to 12345678.

#include "NomadMemory.au3";

Global $Game_ID=WinGetProcess("3D Pinball for Windows - Space Cadet")

;Score address is: 00A90C62

$Address=0x00A90C62
$result = _MemoryOpen($Game_ID)

$CurrentScore=_MemoryRead($Address,$result)

MsgBox(0,"Current score",$CurrentScore)

_MemoryWrite($Address,$result,12345678)

_MemoryClose($result)

Thanks

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...