Little Fighter Empire - Forums

Full Version: [solved] How made state with 4 variables
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi guys.I have made state 5xxxyyy,but how can i make state like 5wwwxxxyyyzzz?

here's example code of state 5xxxyyy:

Code:
devHP:
        CMP EAX,9000000
        jl detectHP
        CMP EAX,9800000
        jge detectHP
        sub eax,9000000
        mov ecx,1000
        mov edx,0
        idiv ecx
        xor ecx,ecx
        mov ecx,eax
        xor eax,eax
        mov eax,edx
        xor edx,edx
        MOV EDX,DWORD PTR DS:[EBX+EDI*4+194h]
        sub dword ptr ds:[edx+2FCh],eax
        cmp dword ptr ds:[edx+2FCh],0
        jle devHP2
        jmp return
        mov dword ptr ds:[edx+2FCh],500
devHP2:
        xor eax,eax
        mov eax,ecx
        mov dword ptr ds:[edx+2FCh],10
        mov dword ptr ds:[edx+70h],eax
        jmp return
You can't. State is parsed and stored as an integer. 5,000,000,000,000 > 2^32.

mov dword ptr ds:[edx+2FCh],500 < that line is never executed, ever.

xor ecx,ecx
xor eax,eax
xor edx,edx

those lines are useless.
5xxxyyyzzz too?
http://www.wolframalpha.com/input/?i=500...0+%3E+2^32


PS: It's actually 2^31 since it is a signed value. Try putting a value like 5000000000 and then parse it with the real time data changer, you'll see lf2 trim the value.

nope I'm wrong :p
http://www.wolframalpha.com/input/?i=500000000+%3E+2^32

5wwxxyyzz can be done! Can you say how do it?
The same way you created 5xxxyyy? I don't understand how you can write that, but can't write 5wwxxyyzz. I'm not sure what to say to help you, it's pretty basic ASM stuff, go learn some x86 ASM and you will be fine...

You can look in itreff.inc, that has some more examples of splitting stuff up.

Edit 2:
I think you are asking me to do it, and I don't want to.
sorry :)


Edit:
Something helpful: You need to use div instead of idiv. Since idiv is for signed values, and
500,000,000 = 11101110011010110010100000000
so yeah, use div.
(02-13-2011, 05:10 PM)Lord Silva Wrote: [ -> ]I think you are asking me to do it, and I don't want to.

No, I want myself to do! Your last post was enough for me to think about! Thank you!
Hooray! I did it! Problem Solved!