| View previous topic :: View next topic |
| Author |
Message |
Sohail__Saha Advanced Cheater
Reputation: 0
Joined: 21 May 2014 Posts: 82 Location: India
|
Posted: Wed Jun 04, 2014 1:05 pm Post subject: Is this auto assembler script incorrect?? |
|
|
In "James Cameron's Avatar-The Game", while trying to make the number of missiles of RDA choppers infinite, I used the following auto assembler script.
--------------------------------
[ENABLE]
alloc(newmem,2048)
label(returnhere)
label(exit)
newmem:
push edi
mov edi,0
mov [eax],edi
pop edi
mov [esi+000002E0],eax
//originalcode:
//mov [esi+000002E0],eax
exit:
jmp returnhere
"Dunia.dll"+6921A6:
jmp newmem
nop
returnhere:
[DISABLE]
dealloc(newmem)
"Dunia.dll"+6921A6:
mov [esi+000002E0],eax
//Alt: db 89 86 E0 02 00 00
--------------------------------
However on enabling the script, the game freezes after firing 1 missile. Is there anything wrong in this script?? _________________
Don't underestimate the power of a common code.
 |
|
| Back to top |
|
 |
NanoByte Expert Cheater
Reputation: 1
Joined: 13 Sep 2013 Posts: 222
|
Posted: Wed Jun 04, 2014 1:22 pm Post subject: |
|
|
| Code: | [ENABLE]
alloc(newmem,2048)
label(returnhere)
label(exit)
newmem:
// all you need to do is this
mov [eax],#100 //replace 100 with the amount u want it to freeze at
// if that dosent work try this "mov eax,#100" put eax without []
//originalcode:
//mov [esi+000002E0],eax |
|
|
| Back to top |
|
 |
Daijobu Master Cheater
Reputation: 13
Joined: 05 Feb 2013 Posts: 301 Location: the Netherlands
|
Posted: Wed Jun 04, 2014 1:52 pm Post subject: |
|
|
If [esi+000002E0] holds the value, mov [esi+000002E0],64 {100 as example}.
In your script you're moving a value into the address eax holds.
Read this: http://forum.cheatengine.org/viewtopic.php?p=5535663#5535663
I suck at explaining things, so I hope that put the point across. _________________
|
|
| Back to top |
|
 |
justa_dude Grandmaster Cheater
Reputation: 23
Joined: 29 Jun 2010 Posts: 893
|
Posted: Wed Jun 04, 2014 3:23 pm Post subject: |
|
|
Maybe better to xor eax or mov eax,0 since the code could be using eax later, for example to set the display. Whatever the case, the issue is that you're currently writing a zero into the address that eax holds (which is likely small enough to be in kernel memory) instead of into eax itself - remove the brackets around the eax and you're golden. _________________
A nagy kapu mellett, mindig van egy kis kapu.
----------------------
Come on... |
|
| Back to top |
|
 |
Sohail__Saha Advanced Cheater
Reputation: 0
Joined: 21 May 2014 Posts: 82 Location: India
|
Posted: Thu Jun 05, 2014 3:58 am Post subject: |
|
|
Hey thanks justa_dude, it works!!  _________________
Don't underestimate the power of a common code.
 |
|
| Back to top |
|
 |
|