Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


Age Of Empires: DE - Resources Hack with Pointer, but I Fail

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
SpeTheof
How do I cheat?
Reputation: 0

Joined: 14 Sep 2009
Posts: 2
Location: Greece

PostPosted: Mon Jan 10, 2022 7:27 am    Post subject: Age Of Empires: DE - Resources Hack with Pointer, but I Fail Reply with quote

Hello, I completely suck at this, i know how to change the value on the dynamic addresses, but I want to make it static so I can just load the cheat table I made and change the values, instead of searching the new values again...

So in age of empires, there is Wood, Food, Stone, Gold
from experience i know wood address always ends up with 4, Food with 0, Gold with C and Stone with 8

The Values are always Float

So having that in mind, i usually add manually the other 3 addresses, and just change the last part, and I get all the values,

Now, let's say I restart the game, the values change again to something similar! They will still end in 4 8 0 C - but i need to rescan all over. So how can I pointer scan this thing, i watched 2 youtube tutorials and I just can't seem to understand things right.

So, a float value, that always ends with 0 4 8 C (food wood stone gold)

when i get what accesses this value
it's

7FF62E74649A - F3 0F10 04 88 - movss xmm0,[rax+rcx*4]

What is the right way of going to the static address?
Back to top
View user's profile Send private message
LeFiXER
Grandmaster Cheater Supreme
Reputation: 20

Joined: 02 Sep 2011
Posts: 1055
Location: 0x90

PostPosted: Mon Jan 10, 2022 8:36 am    Post subject: Reply with quote

Whilst not entirely leading to a static address there is a way you can locate the correct addresses no matter how many times you restart the game. You can do this with AOB injection to pull the value (address) from the registers, RAX + RCX. * 4 is the offset as you said 0 is food, 4 is wood, stone is 8 and gold is C.

It will be something like:
Code:

[ENABLE]
aobscan(aobResources, [array of bytes here])
alloc(newmem,$1000,aobResources)
alloc(resource_pointer,8)          // allocate 8-bytes of memory
label(code)
label(return)

newmem:
  push rbx                         //preserve value held in RBX
  mov rbx,[rax+rcx]                //move dereferenced value (RAX+RCX) into RBX
  mov [resource_pointer],rbx       //move the value held in RBX to the allocated memory address [resource_pointer]
  pop rbx                          //restore RBX

code:
  // original instructions here
  jmp return

aobResources:
  jmp newmem
return:
registersymbol(aobResources)
registersymbol(resource_pointer)   //Register the symbol for use within the table
[DISABLE]

aobResources:
  db //[array of bytes]

unregistersymbol(aobResources)
unregistersymbol(resource_pointer) //Unregister the symbol because we no longer need it
dealloc(newmem)
dealloc(resource_pointer)          //Deallocate the memory we allocated


This will pull the pointer from the registers for use within the table. Once activated, you can add addresses to the table using the referenced allocated memory. Add each address manually with the address:
Code:

[resource_pointer]+offset

Where offset is the offset of each resource.
Back to top
View user's profile Send private message
SpeTheof
How do I cheat?
Reputation: 0

Joined: 14 Sep 2009
Posts: 2
Location: Greece

PostPosted: Tue Jan 11, 2022 8:56 am    Post subject: Reply with quote

LeFiXER wrote:
Whilst not entirely leading to a static address there is a way you can locate the correct addresses no matter how many times you restart the game. You can do this with AOB injection to pull the value (address) from the registers, RAX + RCX. * 4 is the offset as you said 0 is food, 4 is wood, stone is 8 and gold is C.

It will be something like:
Code:

[ENABLE]
aobscan(aobResources, [array of bytes here])
alloc(newmem,$1000,aobResources)
alloc(resource_pointer,8)          // allocate 8-bytes of memory
label(code)
label(return)

newmem:
  push rbx                         //preserve value held in RBX
  mov rbx,[rax+rcx]                //move dereferenced value (RAX+RCX) into RBX
  mov [resource_pointer],rbx       //move the value held in RBX to the allocated memory address [resource_pointer]
  pop rbx                          //restore RBX

code:
  // original instructions here
  jmp return

aobResources:
  jmp newmem
return:
registersymbol(aobResources)
registersymbol(resource_pointer)   //Register the symbol for use within the table
[DISABLE]

aobResources:
  db //[array of bytes]

unregistersymbol(aobResources)
unregistersymbol(resource_pointer) //Unregister the symbol because we no longer need it
dealloc(newmem)
dealloc(resource_pointer)          //Deallocate the memory we allocated


This will pull the pointer from the registers for use within the table. Once activated, you can add addresses to the table using the referenced allocated memory. Add each address manually with the address:
Code:

[resource_pointer]+offset

Where offset is the offset of each resource.


Wow, thanks for the reply! You sure put detail and comments, I wish I knew how to do that though I suck at coding and I really don't understand most of what you made here, is there any way to do that stuff through cheat engine without scripts?

Or if there is any video i could watch to point me to the right direction to apply what you said here

Thank you very much for your reply! I am pretty sure it will help dozens of others too!
Back to top
View user's profile Send private message
LeFiXER
Grandmaster Cheater Supreme
Reputation: 20

Joined: 02 Sep 2011
Posts: 1055
Location: 0x90

PostPosted: Tue Jan 11, 2022 10:05 am    Post subject: Reply with quote

Sure it's not easy when you first start out but nothing ever is. Only when you've applied knowledge you have gained over time you will find it easier and easier moreover that should not deter you from trying.

Here is a link that will show you how to apply what I have mentioned.
https://www.youtube.com/watch?v=2Kkx5pw2uLw

I do recommend that you try out the Cheat Engine tutorial also just to get a feel for how Cheat Engine works.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites