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 


How to load effective address into cheat table symbol

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
Trisolaris
Newbie cheater
Reputation: 0

Joined: 10 Mar 2019
Posts: 18

PostPosted: Sat Mar 11, 2023 10:30 am    Post subject: How to load effective address into cheat table symbol Reply with quote

Hi,
I'm trying to make the address calculated by following instruction accessible as a symbol in my cheat table, while preserving it's orignal function. With my symbol at hand, I want to be able to set the value of the address manually.

Code:
lea rbx,[rdi+0000008C]


If I get rdi and add the 8C offset, I get the correct address.
I've tried the instructions in following thread, but to no avail:
https://forum.cheatengine.org/viewtopic.php?t=586953&sid=1b3c444513a7b65f9876a873a2007a04

Here's what I have so far, which crashes the game.
As always, any help would be appreciated.

Code:
[ENABLE]
aobscanmodule(MyInjectionPoint,MyGame.exe, blah blah unique AoB)
alloc(newmem,$1000,MyInjectionPoint)
alloc(MySymbol, 4)
label(returnhere)
label(originalcode)
label(exit)
registersymbol(MyInjectionPoint)
registersymbol(MySymbol)

MyInjectionPoint:
  jmp newmem
  nop
  nop
returnhere:

newmem:
  lea rbx,[rdi+0000008C]
  mov [MySymbol], rbx

originalcode:
  lea rbx,[rdi+0000008C]

exit:
  jmp returnhere

[DISABLE]
MyInjectionPoint:
db blah blah unique AoB
unregistersymbol(MyInjectionPoint)
unregistersymbol(MySymbol)
dealloc(newmem)
dealloc(MySymbol)
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 458

Joined: 09 May 2003
Posts: 25288
Location: The netherlands

PostPosted: Sat Mar 11, 2023 10:48 am    Post subject: Reply with quote

rbx is 8 bytes long, so change alloc(mysymbol,4) to alloc(mysymbol,8)
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.

Like my help? Join me on Patreon so i can keep helping
Back to top
View user's profile Send private message MSN Messenger
Trisolaris
Newbie cheater
Reputation: 0

Joined: 10 Mar 2019
Posts: 18

PostPosted: Sat Mar 25, 2023 2:03 am    Post subject: Reply with quote

Dark Byte wrote:
rbx is 8 bytes long, so change alloc(mysymbol,4) to alloc(mysymbol,Cool


OMG Rolling Eyes Embarassed
Thanks a lot Dark Byte! I hope I can carve out some time to test this today
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