Lunos
Random Uruguayan User
- 3,114
- Posts
- 15
- Years
- Montevideo (Uruguay)
- Seen yesterday
Hi. Straight to the point, I want to make a NPC that reads the EVs and/or IVs of one of my Pok?mon, but I think that I'm not understanding how JPAN's special 0x7 (which works in the same way as the special 0x8) works.
What I basically came up with, was this:
The only difference that I'm seeing with the script that JPAN wrote as an example is that he used a setvar 0x8004 0x0, but that would mean that my NPC would always check the EVs/IVs of the first Pok?mon in my party, that's why I decided to use the special 0x9F instead.
Observations:
-If I understood it correctly, both the special 0x6 and the special2 are working as if they were 1 command with multiple parameters. I think it basically executes the special 0x7 (JPAN's) which checks the EVs that a Pok?mon has on whatever stat you specify at the var 0x8005 (0x0 is HP, 0x1 Attack and so on) and then it pastes that amount of EVs in the var 0x8006.
-Buffers 1 to 3 are giving me as result the number 44481, but that's naturally impossible. So something's wrong.
Help please? Even a small hint would be wonderful because I really tried to think in a way to make this work, but I just can't.
What I basically came up with, was this:
Code:
#dynamic 0x71BBA0
#org @start
lock
faceplayer
msgbox @string1 0x5
compare 0x800D 0x0
if 0x1 goto @snippet1
special 0x9F
waitstate
compare 0x8004 0x6
if 0x4 goto @snippet1
goto @snippet2
#org @snippet1
release
end
#org @snippet2
faceplayer
special 0x6
setvar 0x8005 0x0
special2 0x8006 0x7
buffernumber 0x0 0x8006
setvar 0x8005 0x1
special2 0x800D 0x7
buffernumber 0x1 0x800D
setvar 0x8005 0x2
special2 0x800D 0x7
buffernumber 0x2 0x800D
msgbox @string2 0x4
closeonkeypress
setvar 0x8005 0x3
special2 0x800D 0x7
buffernumber 0x0 0x800D
setvar 0x8005 0x4
special2 0x800D 0x7
buffernumber 0x1 0x800D
setvar 0x8005 0x5
special2 0x800D 0x7
buffernumber 0x2 0x800D
special 0x6
msgbox @string3 0x4
closeonkeypress
release
end
#org @string1
= Wanna check a POK?MON's EVs?
#org @string2
= Hmm[.] I see, I see.\nYour POK?MON's EVs are:\l[buffer1] EVs in HP, [buffer2] EVs in Atk.\land [buffer3] EVs in Def.
#org @string3
= Followed by [buffer1] EVs in Spd\n[buffer2] EVs in Sp. Atk\land [buffer3] EVs in Sp. Def.
The only difference that I'm seeing with the script that JPAN wrote as an example is that he used a setvar 0x8004 0x0, but that would mean that my NPC would always check the EVs/IVs of the first Pok?mon in my party, that's why I decided to use the special 0x9F instead.
Observations:
-If I understood it correctly, both the special 0x6 and the special2 are working as if they were 1 command with multiple parameters. I think it basically executes the special 0x7 (JPAN's) which checks the EVs that a Pok?mon has on whatever stat you specify at the var 0x8005 (0x0 is HP, 0x1 Attack and so on) and then it pastes that amount of EVs in the var 0x8006.
-Buffers 1 to 3 are giving me as result the number 44481, but that's naturally impossible. So something's wrong.
Help please? Even a small hint would be wonderful because I really tried to think in a way to make this work, but I just can't.
Last edited: