 |
Cheat Engine The Official Site of Cheat Engine
|
| View previous topic :: View next topic |
| Author |
Message |
Blazin Grandmaster Cheater
Reputation: 0
Joined: 17 Sep 2006 Posts: 770 Location: Somewhere over the rainbow.
|
Posted: Fri Jul 04, 2008 8:20 pm Post subject: Minesweeper ASM script? |
|
|
I have recently learned some basic ASM, and I'm trying to make a script to give you unlimited flags. I have found the addresses to use in the script.
The address to edit the number of flags is 01005194.
Now, the problem I'm having is writing the script. When I try, I'm not quite sure when to start.
|
|
| Back to top |
|
 |
Overload Master Cheater
Reputation: 0
Joined: 08 Feb 2008 Posts: 293
|
Posted: Fri Jul 04, 2008 8:32 pm Post subject: |
|
|
There are many minesweeper script examples on CEF. But...
What you would want to do is nop the pointer to the address that decreases your flags. So something similar to this:
| Code: | [enable]
//pointer here:
nop
[disable]
//original code |
I have the exact script you are looking for lying around. If i find it, i'll post it.
EDIT:
yea, here's the script. I just re-wrote it for fun
| Code: | [ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
0100346e:
nop
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
0100346e:
add [01005194], eax |
0100346e is the pointer, incase you didn't figure that out
|
|
| Back to top |
|
 |
Blazin Grandmaster Cheater
Reputation: 0
Joined: 17 Sep 2006 Posts: 770 Location: Somewhere over the rainbow.
|
Posted: Fri Jul 04, 2008 8:53 pm Post subject: |
|
|
| Overload wrote: | There are many minesweeper script examples on CEF. But...
What you would want to do is nop the pointer to the address that decreases your flags. So something similar to this:
| Code: | [enable]
//pointer here:
nop
[disable]
//original code |
I have the exact script you are looking for lying around. If i find it, i'll post it.
EDIT:
yea, here's the script. I just re-wrote it for fun
| Code: | [ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
0100346e:
nop
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
0100346e:
add [01005194], eax |
0100346e is the pointer, incase you didn't figure that out  |
Thanks. I'm trying to write a script to keep the time at 1 also. I'll post it when I'm finished.
|
|
| Back to top |
|
 |
Overload Master Cheater
Reputation: 0
Joined: 08 Feb 2008 Posts: 293
|
Posted: Fri Jul 04, 2008 9:00 pm Post subject: |
|
|
| ok, just make sure you post in this thread if you need help. No need to make a new thread.
|
|
| Back to top |
|
 |
Blazin Grandmaster Cheater
Reputation: 0
Joined: 17 Sep 2006 Posts: 770 Location: Somewhere over the rainbow.
|
Posted: Fri Jul 04, 2008 9:03 pm Post subject: |
|
|
| Overload wrote: | | ok, just make sure you post in this thread if you need help. No need to make a new thread. |
I know, I'm tired of spam too. Good thing spammers from the maple section don't usually come in here. XD
Anyways, here it is. I tried it, and it seems to work.
| Code: | [ENABLE]
alloc(lol,1024)
label(isuckatasm)
label(thanksforthehelp)
lol:
mov [0100579C],5
isuckatasm:
cmp [0100579C],1
je thanksforthehelp
dec [0100579C]
jmp isuckatasm
thanksforthehelp:
[DISABLE]
dealloc(lol) |
EDIT: Whoops, had the wrong address in it. X.x
EDIT#2: It doesn't work, nvm. I had freeze ticked at 1 when i tried my script. Why does it not work?
|
|
| Back to top |
|
 |
me Grandmaster Cheater
Reputation: 2
Joined: 24 Jun 2004 Posts: 733 Location: location location
|
Posted: Fri Jul 04, 2008 9:42 pm Post subject: |
|
|
been a long time since I scripted
does this work for you,
oh wonder if sp1 and sp2 have the same effect on this game as it does on pinball,,,,hmmm
this is an old one by the way,, did it a long time ago
| Code: | [ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
alloc(newmem,2048) //2kb should be enough
label(returnhere)
label(originalcode)
label(exit)
01002FF5:
jmp newmem
nop
returnhere:
newmem: //this is allocated memory, you have read,write,execute access
//place your code here
inc [winmine.exe+579c]
cmp [winmine.exe+579c],5
jne returnhere
mov [winmine.exe+579c],1
jmp returnhere
originalcode:
inc [winmine.exe+579c]
exit:
jmp returnhere
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem) //free memory
inc [winmine.exe+579c]
|
_________________
|
|
| Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8588 Location: 127.0.0.1
|
Posted: Sat Jul 05, 2008 4:14 am Post subject: |
|
|
A simple script to do this would be like this..
Firstly, you need to find the address that holds the value, you do that fairly easy.
1. Search for 10 when you start a new game.
2. Use 1 flag by right clicking anywhere on the board.
3. Search for 9. Usually you will get 1 result right away.
Now, this is simply your storage address, it wont help much writing a script directly for this for unlimited flags, instead freezing the address would suite that purpose. So we need to locate what writes to the address. To do that, add the address to the table by double clicking it in the search results.
Next, right click it, choose 'Find out what writes to this address' then go back in Minesweeper and use a flag again.
The window will show:
0100346e - 01 05 94 51 00 01 - add [01005194], eax
Now we have the instruction that writes to our flags, we can adjust what is done here.
Create a new script and for this code we will use:
| Code: | [ENABLE]
alloc(flagcave,25)
label(flagback)
flagcave:
mov [1005194],A
jmp flagback
100346E:
jmp flagcave
nop
flagback:
[DISABLE]
100346E:
add [1005194],eax
dealloc(flagcave) |
To explain the code, firstly the enable section:
| Code: | [ENABLE]
alloc(flagcave,25)
label(flagback)
flagcave:
mov [1005194],A
jmp flagback
100346E:
jmp flagcave
nop
flagback: |
At the top, we allocate 256 bytes of memory for our cave and name it 'flagcave'. And we also create a label to use to jump back out of our cave.
Next we have the cave code. This simply moves 'A' or 10 in decimal, into the flags storage address then jumps out of the cave back to the original code.
The next part is the original line, we tell it to jump to our cave, and nop the extra byte that is left over. JMP = 5 bytes, the instruction was 6 (01 05 94 51 00 01) so the 01 was left over, so we need to nop it to prevent issues.
Next is the disable section, here we simply replace the original code back to what it was to remove the jump to our cave, then we delete the code cave we created.
Hope that helps.
_________________
- Retired. |
|
| 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
|
|