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 


Assembly code search

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

Joined: 14 Sep 2011
Posts: 87

PostPosted: Mon Mar 25, 2013 10:36 am    Post subject: Assembly code search Reply with quote

when I want to know how many opcode can be using the function that contain an opcode which change the value. I use Search>find assembly code for "call <address>".
Here is my step.
1.find the value that you want.
2.find out what writes to this address to get the opcode.
3.move on top of the opcode until you can get the first opcode of the function(noticed by some pattern like combo of int 3)
4.search in the "find assembly code" for call <address of 1st opcode>

Is instruction "call" the only one I needs to? Is there others instruction or advance method ? Sometime I can't find any result.
Back to top
View user's profile Send private message
Gniarf
Grandmaster Cheater Supreme
Reputation: 43

Joined: 12 Mar 2012
Posts: 1285

PostPosted: Tue Mar 26, 2013 7:38 am    Post subject: Re: Assembly code search Reply with quote

happyreadygo wrote:
Is instruction "call" the only one I needs to? Is there others instruction or advance method ?

Well "call abcdef" can also be written:
Code:
call dword [123456] //call the function whose address is stored at 123456
123456: 00abcdef
or:
Code:
mov eax,abcdef
call eax
there is also:
Code:
mov eax,123456
call dword [eax]
123456: 00abcdef

Plus other variants if you're looking at obfuscated code = parts of a copy protection.

When I want to find all instructions that called a given function, I:
-Note the address of the function.
-Save my CE work.
-Close cheat engine.
-Attach ollydbg 1.10 with detach plugin to my game.
-In olly, set a conditional log breakpoint at the first instruction of my function, asking to always log "dword [esp]" and never pause program.
-Resume execution (F9).
-Play a bit.
-Freeze the game (F12).
-Look at olly's log: every red line is the address just after a call to my function.
-Often do some post processing in excel to remove duplicates.
-Resume game execution.
-Detach olly (plugins->detach->detach from debugee).
-Resume working with CE.

It's quite a lot of hassle, but it will always find all calls that used your function during the time you played in step 7. Well with obfuscated protected code it might not work though...
Back to top
View user's profile Send private message
happyreadygo
Advanced Cheater
Reputation: 1

Joined: 14 Sep 2011
Posts: 87

PostPosted: Tue Mar 26, 2013 8:57 am    Post subject: Reply with quote

thanks , i ll try it Smile
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