 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
Twistedfate Expert Cheater
Reputation: 1
Joined: 11 Mar 2016 Posts: 231
|
Posted: Sun Jun 26, 2016 1:16 am Post subject: Help me to compare value from another address(assembly) |
|
|
Can anybody tell me
1- how to change the type of values to string or 2 byte 4 byte etc :
for example add # before the number to convert the value 4 byte
what could i add to convert the value to float or string ?
___________________________________________________
2nd - I want to compare between the 4 bytes value inside this Mygame.exe+737140 with [esi+160]
I tried to do this but did not work !!
cmp [esi+160] ,Mygame.exe+737140 (Help here) →
I want to compare the value inside Mygame.exe+737140 with [esi+160]
| Code: | [enable]
alloc(newmem,2048)
label(returnhere)
label(originalcode)
label(exit)
newmem:
cmp [esi+160], HelpHere
je originalcode
mov eax,#0
jmp exit
originalcode:
mov eax,[esi+000001D4]
exit:
jmp returnhere
"Mygame.exe"+2D34BA:
jmp newmem
nop
returnhere:
[Disable]
dealloc(newmem)
"Mygame.exe"+2D34BA:
mov eax,[esi+000001D4] |
|
|
| Back to top |
|
 |
ulysse31 Master Cheater
Reputation: 2
Joined: 19 Mar 2015 Posts: 324 Location: Paris
|
Posted: Sun Jun 26, 2016 3:49 am Post subject: Re: Help me to compare value from another address(assembly) |
|
|
| Twistedfate wrote: | Can anybody tell me
1- how to change the type of values to string or 2 byte 4 byte etc :
for example add # before the number to convert the value 4 byte
what could i add to convert the value to float or string ?
___________________________________________________
2nd - I want to compare between the 4 bytes value inside this Mygame.exe+737140 with [esi+160]
I tried to do this but did not work !!
cmp [esi+160] ,Mygame.exe+737140 (Help here) →
I want to compare the value inside Mygame.exe+737140 with [esi+160]
| Code: | [enable]
alloc(newmem,2048)
label(returnhere)
label(originalcode)
label(exit)
newmem:
cmp [esi+160], HelpHere
je originalcode
mov eax,#0
jmp exit
originalcode:
mov eax,[esi+000001D4]
exit:
jmp returnhere
"Mygame.exe"+2D34BA:
jmp newmem
nop
returnhere:
[Disable]
dealloc(newmem)
"Mygame.exe"+2D34BA:
mov eax,[esi+000001D4] |
|
1/ # doesn't convert the value to 4 bytes, it "converts" it to a decimal integer type.
To make it a float you can do as such :
2/
| Code: | [enable]
alloc(newmem,2048)
label(returnhere)
label(originalcode)
label(exit)
newmem:
push ecx
mov ecx,[Mygame.exe+737140]
cmp [esi+160], ecx
je originalcode
mov eax,#0
jmp exit
originalcode:
mov eax,[esi+000001D4]
exit:
pop ecx
jmp returnhere
"Mygame.exe"+2D34BA:
jmp newmem
nop
returnhere:
[Disable]
dealloc(newmem)
"Mygame.exe"+2D34BA:
mov eax,[esi+000001D4] |
|
|
| Back to top |
|
 |
Twistedfate Expert Cheater
Reputation: 1
Joined: 11 Mar 2016 Posts: 231
|
Posted: Sun Jun 26, 2016 11:57 am Post subject: |
|
|
Thank you very much i did what i want to ^^ but is there anyway to keep the changed value saved inside the code continuously ?
I mean every time the code change | Code: | | [Mygame.exe+737140] |
add new lines to my script and run it ?
for example :
| Code: | | [Mygame.exe+737140] | = 7
the code goes like this
cmp [esi+160],#7
je originalcode
mov eax,#0
and another numbers keep saved etc ^^ ?
|
|
| Back to top |
|
 |
ulysse31 Master Cheater
Reputation: 2
Joined: 19 Mar 2015 Posts: 324 Location: Paris
|
Posted: Sun Jun 26, 2016 1:51 pm Post subject: |
|
|
You can store the values into variables which you test but it has to be a defined number of variables (ie it cannot saved an infinite amount of values).
you create variables like this :
you initialize them like this :
| Code: | var:
dd #0
var+4:
dd #0
var+8:
dd #0 |
you test them like this :
| Code: | push ebx
mov ebx,[var]
test ebx,ebx
pop ebx
jne label // this jump is taken if ebx != 0
mov [var],ecx //if var holds 0 you save ecx's value to it |
You may need to work on your assembly a bit first
|
|
| 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
|
|