 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
cobolt78 How do I cheat?
Reputation: 0
Joined: 02 Jun 2014 Posts: 2 Location: Australia
|
Posted: Mon Jun 02, 2014 7:46 pm Post subject: AOB scan with cmp help |
|
|
Hi, This is my first attempt at an AOB, I am trying an inf health script, I finally got it too work with one exception, my cmp no longer works and i cannot figure out why.
If I dont use cmp with my AOB script the enemy will not die. If i insert hard coded addresses instead of an AOB with my cmp it works great, but as soon as i restart the game the address changes hence why i'm using AOB method.
The game does not crash when enabled or disabled I just continue to loose health and so does the enemy.
| Code: | [ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
aobscan(aob1,F3 0F 11 43 14 48 8B CB E8)
alloc(newmem,2048,aob1)
label(returnhere)
label(originalcode)
label(exit)
label(injectpoint)
registersymbol(injectpoint)
newmem: //this is allocated memory, you have read,write,execute access
//place your code here
//movss [rbx+14],xmm0
cmp [rbx+90],0 //<-- 0 is me 1 is enemy
jne originalcode
mov [rbx+14],(float)100
originalcode:
movss [rbx+14],xmm0
exit:
jmp injectpoint
aob1:
injectpoint:
jmp newmem
nop
returnhere:
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
//7FE98A5F402:
dealloc(newmem)
injectpoint:
movss [rbx+14],xmm0
unregistersymbol(injectpoint)
//Alt: db F3 0F 11 43 14
|
thx for your help in advance
|
|
| Back to top |
|
 |
justa_dude Grandmaster Cheater
Reputation: 23
Joined: 29 Jun 2010 Posts: 893
|
Posted: Mon Jun 02, 2014 9:28 pm Post subject: |
|
|
Set a breakpoint on the compare in your script and ensure that it's checking the correct address and that the value what you think it is. The most likely cause would be that your aob is wrong, but stepping through the code should tell you for sure.
_________________
A nagy kapu mellett, mindig van egy kis kapu.
----------------------
Come on... |
|
| Back to top |
|
 |
Geri Moderator
Reputation: 112
Joined: 05 Feb 2010 Posts: 5627
|
Posted: Mon Jun 02, 2014 9:29 pm Post subject: |
|
|
| Code: | exit:
jmp injectpoint |
You shouldn't have changed this. It was originally
exit:
jmp returnhere
and it should stay that way.
(And since your script is an endless loop, which would result in a "freeze", I doubt that it was executed at all. Which means that your AOB is probably also wrong and it was injected at a code that was luckily not used by the game.)
_________________
|
|
| Back to top |
|
 |
cobolt78 How do I cheat?
Reputation: 0
Joined: 02 Jun 2014 Posts: 2 Location: Australia
|
Posted: Mon Jun 02, 2014 10:44 pm Post subject: |
|
|
| Geri wrote: | | Code: | exit:
jmp injectpoint |
You shouldn't have changed this. It was originally
exit:
jmp returnhere
and it should stay that way.
(And since your script is an endless loop, which would result in a "freeze", I doubt that it was executed at all. Which means that your AOB is probably also wrong and it was injected at a code that was luckily not used by the game.) |
thx for your advice Geri, you solved my problem. I guess i shouldnt of touched jmp returnhere lol, and put in jmp exit after newmem code and now works flawlessly, although still not 100% sure exactly what everything does
but glad it works after hours and hours on this, hopefully AOB's will be easier for me next time.
| Code: |
[ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
aobscan(aob1,F3 0F 11 43 14 48 8B CB E8)
alloc(newmem,2048,aob1)
label(returnhere)
label(originalcode)
label(exit)
label(injectpoint)
registersymbol(injectpoint)
newmem: //this is allocated memory, you have read,write,execute access
//place your code here
//movss [rbx+14],xmm0
cmp [rbx+90],(float)0
jne originalcode
mov [rbx+14],(float)100
jmp exit //<--NEW
originalcode:
movss [rbx+14],xmm0
exit:
jmp returnhere //<--NEW
aob1:
injectpoint:
jmp newmem
returnhere:
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
//7FE98A5F402:
dealloc(newmem)
injectpoint:
movss [rbx+14],xmm0
unregistersymbol(injectpoint)
//Alt: db F3 0F 11 43 14 |
|
|
| Back to top |
|
 |
|
|
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
|
|