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 


[Help]Code Cave problems

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

Joined: 09 Feb 2008
Posts: 3

PostPosted: Sat Feb 09, 2008 4:20 pm    Post subject: [Help]Code Cave problems Reply with quote

Hey CE players.

I've been having the weirdest problem with my ASM code cave.

let me lay it out with my original code and how I set up my code cave.

Code:

//original no jumps....
JE      009000F6
MOV     EDX, DWORD PTR [EDX+5C]
MOV     DWORD PTR [EBP-4], EDX
MOV     ECX, DWORD PTR [ECX+1C0]


Code:
Here's my code cave that I end up with
//As you can see I'm trying to get inside the pointer "[EDX+5C]"
JE      009000F6
MOV    DWORD PTR [EDX+5C], 0x00000
MOV     EDX, DWORD PTR [EDX+5C]
MOV     DWORD PTR [EBP-4], EDX
MOV     ECX, DWORD PTR [ECX+1C0]
jmp 009000FC


Thing is I keep crashing like mad, when I try to access this function.

Any help would be great.

Thanks,
-Somen00b2
Back to top
View user's profile Send private message
Labyrnth
Moderator
Reputation: 10

Joined: 28 Nov 2006
Posts: 6301

PostPosted: Sat Feb 09, 2008 4:33 pm    Post subject: Reply with quote

Cant really tell what your doing by this.

crashing because.....

1. Left over bytes in original flow of the code.
2. The cave is not large enough or being used by some other part of the game.
3. Your not jumping back to the right location in the flow of the original code.
Back to top
View user's profile Send private message
Somen00b2
How do I cheat?
Reputation: 0

Joined: 09 Feb 2008
Posts: 3

PostPosted: Sat Feb 09, 2008 5:58 pm    Post subject: Reply with quote

Well can you tell me this... How I have it set up in the code cave.. Is that the correct way?
Back to top
View user's profile Send private message
Labyrnth
Moderator
Reputation: 10

Joined: 28 Nov 2006
Posts: 6301

PostPosted: Sat Feb 09, 2008 6:19 pm    Post subject: Reply with quote

No your not, Because that jmp you are writing after the original code is over writing bytes of valuable code.

Here is the order you need to do it.
Code:

label(back)
* Code cave address
*What your writing to the cave
jmp back

*Original address
jmp *code cave address
nop  <-- may need more then one to clean up the left over bytes.
back:


jmp 009000FC
Also i do not think this is a cave, since it is only 6 address away from the original JE 009000F6




Here is all i can do with what you have provided, I cannot test it.
Plus you never said what game this is.
Code:

[ENABLE]
label(back)

*Code Cave Address:
MOV DWORD PTR [EDX+5C],0x00000
MOV EDX,DWORD PTR [EDX+5C]
jmp back

*Original address:
jmp *Code cave Address
nop
back:

[DISABLE]
*Original Address:
MOV EDX,DWORD PTR [EDX+5C]


Last edited by Labyrnth on Sat Feb 09, 2008 6:33 pm; edited 3 times in total
Back to top
View user's profile Send private message
hcavolsdsadgadsg
I'm a spammer
Reputation: 26

Joined: 11 Jun 2007
Posts: 5801

PostPosted: Sat Feb 09, 2008 6:30 pm    Post subject: Re: [Help]Code Cave problems Reply with quote

Somen00b2 wrote:
Hey CE players.

I've been having the weirdest problem with my ASM code cave.

let me lay it out with my original code and how I set up my code cave.

Code:

//original no jumps....
JE      009000F6
MOV     EDX, DWORD PTR [EDX+5C]
MOV     DWORD PTR [EBP-4], EDX
MOV     ECX, DWORD PTR [ECX+1C0]


Code:
Here's my code cave that I end up with
//As you can see I'm trying to get inside the pointer "[EDX+5C]"
JE      009000F6
MOV    DWORD PTR [EDX+5C], 0x00000
MOV     EDX, DWORD PTR [EDX+5C]
MOV     DWORD PTR [EBP-4], EDX
MOV     ECX, DWORD PTR [ECX+1C0]
jmp 009000FC


Thing is I keep crashing like mad, when I try to access this function.

Any help would be great.

Thanks,
-Somen00b2


You're trying to write your own stuff BEFORE going to a cave and doing it. Remember when you jump to your cave, to restore whatever you destroyed to make the jump first, THEN carry on to your own stuff, THEN jump back.

Use the code cave scanner in the memory searcher and find a nice big space that you can write to.


edit: and that's what I get for not reading the entire topic. Confused
Back to top
View user's profile Send private message
Labyrnth
Moderator
Reputation: 10

Joined: 28 Nov 2006
Posts: 6301

PostPosted: Sat Feb 09, 2008 6:35 pm    Post subject: Re: [Help]Code Cave problems Reply with quote

slovach wrote:

edit: and that's what I get for not reading the entire topic. Confused


Not really it still can help. Razz
Back to top
View user's profile Send private message
Somen00b2
How do I cheat?
Reputation: 0

Joined: 09 Feb 2008
Posts: 3

PostPosted: Sat Feb 09, 2008 8:35 pm    Post subject: Reply with quote

I've found the problem.

simple fix.... Don't use premade apps to do your Code Caves Confused .....

Thanks for your time though.
Back to top
View user's profile Send private message
Labyrnth
Moderator
Reputation: 10

Joined: 28 Nov 2006
Posts: 6301

PostPosted: Sat Feb 09, 2008 8:38 pm    Post subject: Reply with quote

Huh?
Man you can use CE to get you a cave, or ollydbg.
There are some more code cave tools that work as well.
But ollydbg and or CE i would use.
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