Minecraft Block-id

Need Help With an Existing Feature in Memory Hacking Software? Ask Here

Moderators: g3nuin3, SpeedWing, WhiteHat, mezzo

Minecraft Block-id

Postby efficacy » Wed Aug 03, 2011 7:54 am

Right now, I can only change ALL the block types. But, I want a hack that changes only specific blocks. For this one, I want it to change everything non-air to wood. The code below doesn't work, so what's wrong with it? Here's my code:

Code: Select all
[ENABLE]
alloc(newmem,2048)
label(returnhere)
label(exit)
label(air)
label(other)
label(aoblab)
registersymbol(aoblab)
aobscan(aobaob,0f be 44 * 0c 81 e0 ff 00 00 00 83 c4 18) //Array is always correct and returns one result from scan

newmem:
cmp byte ptr [edi+edx+0C],0 //If is air, then do nothing
je air
cmp byte ptr [edi+edx+0C],0 //If not air, then change to wood
jne other

air:
movsx eax,byte ptr [edi+edx+0C] //Do nothing
jmp newmem

other:
mov byte ptr [edi+edx+0C],11 //Change to wood
jmp newmem

exit:
jmp returnhere

aobaob:
aoblab:
jmp newmem
returnhere:

[DISABLE]
dealloc(newmem)
aoblab:
movsx eax,byte ptr [edi+edx+0C]
unregistersymbol(aoblab)
I like pie so much, that no group could ever sum up to the value of how much of I like pie.
efficacy
I Have A Few Questions
 
Posts: 6
Joined: Thu Aug 05, 2010 11:13 am

Re: Minecraft Block-id

Postby L. Spiro » Wed Aug 03, 2011 6:10 pm

Make a working prototype in L. Spiro Script that works and prints which blocks are air and which are not.
Then convert to ASM. After doing so you should be able to find out what is wrong on your own.


L. Spiro
Our songs remind you of songs you’ve never heard.
User avatar
L. Spiro
L. Spiro
 
Posts: 3127
Joined: Mon Jul 17, 2006 10:14 pm
Location: Tokyo, Japan

Minecraft Inconsistent Crashing

Postby efficacy » Wed Aug 03, 2011 11:35 pm

Ok, thanks L. Spiro. I have fixed the code, but now I have a new problem: Minecraft crashes sometimes. One time I turn it on, it works. The next time, it crashes.
Here's my new code:

Code: Select all
[ENABLE]
alloc(newmem,2048)
label(returnhere)
label(exit)
label(aoblab)
registersymbol(aoblab)
aobscan(aobaob,0f be 44 * 0c 81 e0 ff 00 00 00 83 c4 18) //Array is always correct and returns one result from scan

aobaob:
aoblab:
call newmem
returnhere:

newmem:
movsx eax,byte ptr [edi+edx+0C] //Orignal code
pushfd
cmp byte ptr [edi+edx+0C],0 //If the block is air...
je short exit //Go to exit
mov byte ptr [edi+edx+0C],11 //If the block is not air, then change to wood
exit:
popfd
ret

[DISABLE]
dealloc(newmem)
aoblab:
movsx eax,byte ptr [edi+edx+0C]
unregistersymbol(aoblab)


Thx for the reply btw. c:
I like pie so much, that no group could ever sum up to the value of how much of I like pie.
efficacy
I Have A Few Questions
 
Posts: 6
Joined: Thu Aug 05, 2010 11:13 am

Re: Minecraft Block-id

Postby L. Spiro » Fri Aug 05, 2011 12:15 pm

Are you using MHS for this?

You will have to debug it to find out why it crashes. There is no easy answer nor solution for this.
You can reduce possibilities by eliminating parts of your code at a time, but be sure that the code remains stable as you do so.


L. Spiro
Our songs remind you of songs you’ve never heard.
User avatar
L. Spiro
L. Spiro
 
Posts: 3127
Joined: Mon Jul 17, 2006 10:14 pm
Location: Tokyo, Japan


Return to Help

Who is online

Users browsing this forum: Google [Bot] and 2 guests

cron