Minecraft Block-id
Posted: 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)