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 do aob swap ??

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

Joined: 21 May 2011
Posts: 46

PostPosted: Sun Mar 01, 2015 11:30 am    Post subject: how to do aob swap ?? Reply with quote

Hi I would like to know how to do a aobswap within a script.

for example i have this aob 89 4A 2C 8B 4A 2C 85 C9

i would like to swap with C7 42 2C FF 00 00 00 90

so how do i write an example script for it??

the example doesn't need any meaning behind it. it's just an example.


thanks in advance.
Back to top
View user's profile Send private message
aikoncwd
Grandmaster Cheater
Reputation: 23

Joined: 21 Dec 2012
Posts: 591
Location: Spain (Barcelona)

PostPosted: Sun Mar 01, 2015 2:52 pm    Post subject: Re: how to do aob swap ?? Reply with quote

oyyzj wrote:
Hi I would like to know how to do a aobswap within a script.

for example i have this aob 89 4A 2C 8B 4A 2C 85 C9

i would like to swap with C7 42 2C FF 00 00 00 90

so how do i write an example script for it??

the example doesn't need any meaning behind it. it's just an example.


thanks in advance.


Code:

[ENABLE]

aobscanmodule(SomeShit,mygame.exe,89 4A 2C 8B 4A 2C 85 C9)
alloc(newmem,$1000)

label(code)
label(return)

newmem:

code:
  db C7 42 2C FF 00 00 00 90
  jmp return

SomeShit:
  jmp code
return:
registersymbol(SomeShit)

[DISABLE]

PedestalItemSwap:
  db 89 4A 2C 8B 4A 2C 85 C9

unregistersymbol(SomeShit)
dealloc(newmem)


I think this will work

_________________
Hey Hitler
Test here your skill with CheatEngine, I coded a challenge for you. Try to beat it!
HERE
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Sun Mar 01, 2015 3:46 pm    Post subject: Reply with quote

You can make it even simpler.

Code:
[ENABLE]
aobscanmodule(hack,game.exe,89 4A 2C 8B 4A 2C 85 C9)
hack:
  db C7 42 2C FF 00 00 00 90
registersymbol(hack)

[DISABLE]
hack:
  db 89 4A 2C 8B 4A 2C 85 C9
unregistersymbol(hack)
Back to top
View user's profile Send private message
oyyzj
Cheater
Reputation: 0

Joined: 21 May 2011
Posts: 46

PostPosted: Sun Mar 01, 2015 4:49 pm    Post subject: Reply with quote

Zanzer wrote:
You can make it even simpler.

Code:
[ENABLE]
aobscanmodule(hack,game.exe,89 4A 2C 8B 4A 2C 85 C9)
hack:
  db C7 42 2C FF 00 00 00 90
registersymbol(hack)

[DISABLE]
hack:
  db 89 4A 2C 8B 4A 2C 85 C9
unregistersymbol(hack)


Thanks Zanzer. This works great. Now to the next stage.

i have now this aob: * * 60 * * 66 * * * 46 * * * 80 * * D6 D2 66 * * 48

and i want swap like this: * * 60 * * 66 * * * 46 * * * 80 * * D6 25 D0 0F 02 48

so how to do this version? i tried use your example above but that isn't working with this one.

appreciate again
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Sun Mar 01, 2015 4:55 pm    Post subject: Reply with quote

Be sure to replace those XX's with the actual code in the disable script.

And don't use the same "hack" name for multiple scripts. Smile

Code:
[ENABLE]
aobscanmodule(hack,game.exe,* * 60 * * 66 * * * 46 * * * 80 * * D6 D2 66 * * 48)
hack+11:
  db 25 D0 0F 02
registersymbol(hack)

[DISABLE]
hack+11:
  db D2 66 XX XX
unregistersymbol(hack)
Back to top
View user's profile Send private message
oyyzj
Cheater
Reputation: 0

Joined: 21 May 2011
Posts: 46

PostPosted: Sun Mar 01, 2015 6:33 pm    Post subject: Reply with quote

Zanzer wrote:
Be sure to replace those XX's with the actual code in the disable script.

And don't use the same "hack" name for multiple scripts. Smile

Code:
[ENABLE]
aobscanmodule(hack,game.exe,* * 60 * * 66 * * * 46 * * * 80 * * D6 D2 66 * * 48)
hack+11:
  db 25 D0 0F 02
registersymbol(hack)

[DISABLE]
hack+11:
  db D2 66 XX XX
unregistersymbol(hack)


hack+11 ?? not +17 ? where it begins to swap right?
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Sun Mar 01, 2015 7:58 pm    Post subject: Reply with quote

It's hex 11. Smile
Back to top
View user's profile Send private message
oyyzj
Cheater
Reputation: 0

Joined: 21 May 2011
Posts: 46

PostPosted: Mon Mar 02, 2015 12:15 pm    Post subject: Reply with quote

Zanzer wrote:
It's hex 11. Smile


got it . thanks
Back to top
View user's profile Send private message
panraven
Grandmaster Cheater
Reputation: 55

Joined: 01 Oct 2008
Posts: 942

PostPosted: Tue Mar 03, 2015 4:06 pm    Post subject: Reply with quote

Zanzer wrote:
Be sure to replace those XX's with the actual code in the disable script.

And don't use the same "hack" name for multiple scripts. Smile

Code:
[ENABLE]
aobscanmodule(hack,game.exe,* * 60 * * 66 * * * 46 * * * 80 * * D6 D2 66 * * 48)
hack+11:
  db 25 D0 0F 02
registersymbol(hack)

[DISABLE]
hack+11:
  db D2 66 XX XX
unregistersymbol(hack)



Manually replacing the XX XX part on [DISABLE] defeat the purpose of using wildcard, try this:

Code:

aobscan(_hack,60 ?? ?? 66 ?? ?? ?? 46 ?? ?? ?? 80 ?? ?? D6 D2 66 ?? ?? 48 )
alloc(_save_hack,256)   
_save_hack:
readmem(_hack,256)      // order matter in AA script, readmem before making change
_hack+0f:
db 25 d0 0f 02
registersymbol(_hack)
registersymbol(_save_hack)

[DISABLE]
_hack+0f:
readmem(_save_hack+0f,4) // same offset as the modified part, but from saved version
unregistersymbol(_hack)
dealloc(_save_hack)
unregistersymbol(_save_hack)


It use readmem to save and restore the wildcard part.

btw, [DISABLE]section for Flash/Unity Bytecode modification is kind of meaningless except for the rare case that there is known *swf /*dll scanner for cheat dectection (I never encounter one on web game, may be some steam game...).
reason: Once the bytecode jit-compiled to native code, the native code cannot be undone or changed by reversing the byte of modified bytecode.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Tutorials 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