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 


CODE INJECTION HELP

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

Joined: 15 Apr 2020
Posts: 39

PostPosted: Tue May 19, 2020 3:28 pm    Post subject: CODE INJECTION HELP Reply with quote

Good evening, in my injection code instead of API_x64.exe+FCDC50 I would like to put the future address of the line where there is lea eax, [rcx + 09] (the last line of my script)
How to do ?


alloc(newmem,2048,"API_x64.exe"+FCDC50)
label(returnhere)
label(originalcode)
label(exit)

newmem: //this is allocated memory, you have read,write,execute access
ja API_x64.exe+FCDC50
cmp ecx,01
cmove eax,r8d
cmp eax,3F
ja API_x64.exe+FCDC50
mov rdx,[r9+rax*8]
test rdx,rdx
je API_x64.exe+FCDC50
cmp [rdx+00000118],r12d
je API_x64.exe+FCDC50
cmp [rdx+0000011C],r12d
je API_x64.exe+FCDC50
mov eax,ebx
mov [rbp+rax*8+000012D0],rdx
mov ebx,[rbp-70]
inc ebx
mov [rbp-70],ebx
lea eax,[rcx+09]


originalcode:
lea eax,[rcx+08]
cmp eax,09

exit:
jmp returnhere

"API_x64.exe"+FCDC50:
jmp newmem
nop
returnhere:
Back to top
View user's profile Send private message
happyTugs
Cheater
Reputation: 0

Joined: 23 Apr 2020
Posts: 26

PostPosted: Thu May 21, 2020 5:37 am    Post subject: Reply with quote

Quote:
instead of API_x64.exe+FCDC50 I would like to put the future address of the line where there is lea eax, [rcx + 09]

So you want to jump to 'orginalcode' instead? If that's the case, just replace the jumps to API_x64.exe+FCDC50 with the label that you want to jump to (i.e orginalcode).

_________________
This is a block of text that can be added to posts you make. There is a 300 character limit
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