#dynamic 0x800000
#include stditems.rbh
//---------------
#org @start
lock
faceplayer
checkflag 0x2
if 0x1 goto @snippet1
compare 0x4055 0x9
if 0x1 goto @snippet2
compare 0x4055 0x8
if 0x1 goto @snippet3
compare 0x4052 0x1
if 0x1 goto @snippet2
compare 0x4055 0x6
if 0x1 goto @snippet4
compare 0x4057 0x1
if 0x4 goto @snippet5
compare 0x4055 0x4
if 0x1 goto @snippet6
compare 0x4055 0x3
if 0x1 goto @snippet7
msgbox @string1 MSG_KEEPOPEN //"OAK: Now, [player].\pInside those ..."
release
end
//---------------
#org @snippet1
msgbox @string2 MSG_KEEPOPEN //"Thank you, [player]!\nSincerely, t..."
release
end
//---------------
#org @snippet2
call @snippet8
checkflag 0x2F4
if 0x1 goto @snippet9
release
end
//---------------
#org @snippet3
msgbox @string3 MSG_KEEPOPEN //"POKéMON around the world wait for\..."
release
end
//---------------
#org @snippet4
setvar 0x8004 0x0
special2 LASTRESULT 0xD4
copyvar 0x8008 0x8005
copyvar 0x8009 0x8006
buffernumber 0x0 0x8008
buffernumber 0x1 0x8009
compare 0x8009 0x1
if 0x1 goto @snippet10
goto @snippet2
//---------------
#org @snippet5
msgbox @string4 MSG_KEEPOPEN //"OAK: Oh, [player]!\nHow is my old ..."
textcolor 0x3
fanfare 0x105
preparemsg @string5 //"[player] delivered OAK'S PARCEL."
waitmsg
waitfanfare
call @snippet11
removeitem ITEM_OAKSPARCEL 0x1
msgbox @string6 MSG_KEEPOPEN //"Ah! \nIt's the custom POKé BALL!\p..."
playsong 0x13B 0x0
msgbox @string7 MSG_KEEPOPEN //"[rival]: Gramps!"
closeonkeypress
compare PLAYERFACING 0x2
if 0x1 call @snippet12
compare PLAYERFACING 0x1
if 0x1 call @snippet13
compare PLAYERFACING 0x4
if 0x1 call @snippet14
compare PLAYERFACING 0x3
if 0x1 call @snippet14
fadedefault
msgbox @string8 MSG_KEEPOPEN //"[rival]: I almost forgot!\nWhat di..."
closeonkeypress
pause 0x1E
sound 0x15
applymovement 0x4 @move1
waitmovement 0x0
applymovement 0x4 @move2
waitmovement 0x0
compare PLAYERFACING 0x1
if 0x1 call @snippet15
compare PLAYERFACING 0x4
if 0x1 call @snippet16
compare PLAYERFACING 0x3
if 0x1 call @snippet17
compare PLAYERFACING 0x2
if 0x1 call @snippet18
msgbox @string9 MSG_KEEPOPEN //"OAK: Oh, right!\nI have a request ..."
closeonkeypress
compare PLAYERFACING 0x2
if 0x1 call @snippet19
compare PLAYERFACING 0x1
if 0x1 call @snippet20
compare PLAYERFACING 0x4
if 0x1 call @snippet21
compare PLAYERFACING 0x3
if 0x1 call @snippet22
msgbox @string10 MSG_KEEPOPEN //"On the desk there is my invention,..."
closeonkeypress
pause 0x28
msgbox @string11 MSG_KEEPOPEN //"OAK: [player] and [rival].\nTake t..."
closeonkeypress
applymovement 0x4 @move3
waitmovement 0x0
hidesprite 0x9
pause 0xA
hidesprite 0xA
pause 0x19
compare PLAYERFACING 0x2
if 0x1 call @snippet23
compare PLAYERFACING 0x1
if 0x1 call @snippet24
compare PLAYERFACING 0x4
if 0x1 call @snippet25
compare PLAYERFACING 0x3
if 0x1 call @snippet26
pause 0xA
textcolor 0x3
fanfare 0x13E
preparemsg @string12 //"[player] received the POKéDEX\nfro..."
waitmsg
waitfanfare
call @snippet11
setflag 0x829
special 0x181
setvar 0x407C 0x1
msgbox @string13 MSG_KEEPOPEN //"OAK: You can't get detailed data\n..."
additem ITEM_POKEBALL 0x5
loadpointer 0x0 @string14 //"[player] received five POKé BALLS."
giveitem2 ITEM_POKEBALL 0x5 0x101
msgbox @string15 MSG_KEEPOPEN //"When a wild POKéMON appears,\nit's..."
setvar 0x8004 0x0
setvar 0x8005 0x1
special 0x173
msgbox @string16 MSG_KEEPOPEN //"To make a complete guide on all\nt..."
msgbox @string17 MSG_KEEPOPEN //"[rival]: All right, Gramps!\nLeave..."
compare PLAYERFACING 0x2
if 0x1 call @snippet27
compare PLAYERFACING 0x1
if 0x1 call @snippet28
compare PLAYERFACING 0x4
if 0x1 call @snippet29
compare PLAYERFACING 0x3
if 0x1 call @snippet29
msgbox @string18 MSG_KEEPOPEN //"[player], I hate to say it, but yo..."
closeonkeypress
playsong 0x13C 0x0
compare PLAYERFACING 0x2
if 0x1 call @snippet30
compare PLAYERFACING 0x1
if 0x1 call @snippet31
compare PLAYERFACING 0x4
if 0x1 call @snippet31
compare PLAYERFACING 0x3
if 0x1 call @snippet31
hidesprite 0x8
fadedefault
setvar 0x4055 0x6
setvar 0x4057 0x2
setvar 0x4051 0x1
setvar 0x4058 0x1
setvar 0x4054 0x1
release
end
//---------------
#org @snippet6
msgbox @string19 MSG_KEEPOPEN //"OAK: [player], raise your young\nP..."
release
end
//---------------
#org @snippet7
msgbox @string20 MSG_KEEPOPEN //"OAK: If a wild POKéMON appears,\ny..."
release
end
//---------------
#org @snippet8
special 0x187
compare LASTRESULT 0x2
if 0x1 goto @snippet32
special 0x188
checkflag 0x2F4
if 0x1 call @snippet33
checkflag 0x2F4
if 0x0 call @snippet34
call @snippet35
return
//---------------
#org @snippet9
closeonkeypress
pause 0x28
preparemsg @string21 //"Wroooooooaaaaaarrrr!"
waitmsg
compare PLAYERFACING 0x2
if 0x1 call @snippet36
compare PLAYERFACING 0x1
if 0x1 call @snippet37
compare PLAYERFACING 0x4
if 0x1 call @snippet38
compare PLAYERFACING 0x3
if 0x1 call @snippet39
applymovement 0x4 @move4
waitmovement 0x0
closeonkeypress
pause 0x46
msgbox @string2 MSG_KEEPOPEN //"Thank you, [player]!\nSincerely, t..."
setflag 0x2
release
end
//---------------
#org @snippet10
special 0x187
compare LASTRESULT 0x2
if 0x1 goto @snippet32
special 0x188
checkflag 0x24F
if 0x1 goto @snippet3
checkflag 0x247
if 0x1 goto @snippet40
checkitem ITEM_POKEBALL 0x1
compare LASTRESULT 0x0
if 0x1 goto @snippet41
goto @snippet3
//---------------
#org @snippet11
copyvar 0x8012 0x8013
return
//---------------
#org @snippet12
movesprite2 0x8 0x5 0xA
showsprite 0x8
applymovement MOVE_PLAYER @move5
applymovement 0x8 @move6
waitmovement 0x0
return
//---------------
#org @snippet13
movesprite2 0x8 0x6 0xA
showsprite 0x8
applymovement 0x4 @move7
applymovement 0x8 @move6
waitmovement 0x0
return
//---------------
#org @snippet14
movesprite2 0x8 0x6 0xA
showsprite 0x8
applymovement 0x4 @move7
applymovement MOVE_PLAYER @move8
applymovement 0x8 @move6
waitmovement 0x0
return
//---------------
#org @snippet15
applymovement 0x4 @move4
waitmovement 0x0
pause 0xF
applymovement 0x4 @move7
waitmovement 0x0
return
//---------------
#org @snippet16
applymovement 0x4 @move4
waitmovement 0x0
pause 0xF
applymovement MOVE_PLAYER @move9
applymovement 0x4 @move7
waitmovement 0x0
return
//---------------
#org @snippet17
applymovement 0x4 @move4
waitmovement 0x0
pause 0xF
applymovement MOVE_PLAYER @move10
applymovement 0x4 @move7
waitmovement 0x0
return
//---------------
#org @snippet18
applymovement MOVE_PLAYER @move3
waitmovement 0x0
return
//---------------
#org @snippet19
applymovement 0x4 @move11
waitmovement 0x0
return
//---------------
#org @snippet20
applymovement 0x4 @move12
applymovement MOVE_PLAYER @move13
applymovement 0x8 @move13
waitmovement 0x4
return
//---------------
#org @snippet21
applymovement 0x4 @move11
applymovement MOVE_PLAYER @move14
waitmovement 0x4
return
//---------------
#org @snippet22
applymovement 0x4 @move11
waitmovement 0x0
return
//---------------
#org @snippet23
applymovement 0x4 @move15
waitmovement 0x0
return
//---------------
#org @snippet24
applymovement 0x4 @move16
waitmovement 0x0
return
//---------------
#org @snippet25
applymovement 0x4 @move15
applymovement MOVE_PLAYER @move17
waitmovement 0x0
return
//---------------
#org @snippet26
applymovement 0x4 @move15
waitmovement 0x0
return
//---------------
#org @snippet27
applymovement 0x8 @move4
applymovement MOVE_PLAYER @move10
waitmovement 0x0
return
//---------------
#org @snippet28
applymovement 0x8 @move3
applymovement MOVE_PLAYER @move7
waitmovement 0x0
return
//---------------
#org @snippet29
applymovement 0x8 @move4
applymovement MOVE_PLAYER @move7
waitmovement 0x0
return
//---------------
#org @snippet30
applymovement MOVE_PLAYER @move8
applymovement 0x8 @move18
waitmovement 0x0
return
//---------------
#org @snippet31
applymovement 0x8 @move18
waitmovement 0x0
return
//---------------
#org @snippet32
release
end
//---------------
#org @snippet33
msgbox @string22 MSG_KEEPOPEN //"OAK: Ah, welcome!\pTell me, how is..."
return
//---------------
#org @snippet34
msgbox @string23 MSG_KEEPOPEN //"OAK: Good to see you!\nHow is your..."
return
//---------------
#org @snippet35
setvar 0x8004 0x1F
special 0x17E
special 0x17D
setvar 0x8004 0x0
special2 LASTRESULT 0xD4
copyvar 0x8008 0x8005
copyvar 0x8009 0x8006
copyvar 0x800A LASTRESULT
buffernumber 0x0 0x8008
buffernumber 0x1 0x8009
msgbox @string24 MSG_KEEPOPEN //"The amount of progress you've made..."
checkflag 0x2FF
if 0x0 call @snippet42
call @snippet43
compare 0x800A 0x0
if 0x1 goto @snippet44
setvar 0x8004 0x1
special2 LASTRESULT 0xD4
copyvar 0x8008 0x8005
copyvar 0x8009 0x8006
buffernumber 0x0 0x8008
buffernumber 0x1 0x8009
msgbox @string25 MSG_KEEPOPEN //"And your NATIONAL POKéDEX is:\p[bu..."
special2 LASTRESULT 0x1B0
compare LASTRESULT 0x0
if 0x1 goto @snippet45
compare LASTRESULT 0x1
if 0x1 goto @snippet46
end
//---------------
#org @snippet36
applymovement 0x4 @move19
waitmovement 0x0
return
//---------------
#org @snippet37
applymovement 0x4 @move20
waitmovement 0x0
return
//---------------
#org @snippet38
applymovement 0x4 @move21
waitmovement 0x0
return
//---------------
#org @snippet39
applymovement 0x4 @move22
waitmovement 0x0
return
//---------------
#org @snippet40
msgbox @string26 MSG_KEEPOPEN //"OAK: Come see me sometime.\pAfter ..."
release
end
//---------------
#org @snippet41
compare 0x4054 0x2
if 0x4 goto @snippet47
goto @snippet3
//---------------
#org @snippet42
textcolor 0x0
return
//---------------
#org @snippet43
copyvar 0x8004 0x8009
special 0xD5
waitmsg
compare LASTRESULT 0x0
if 0x1 call @snippet48
compare LASTRESULT 0x1
if 0x1 call @snippet49
waitfanfare
waitkeypress
return
//---------------
#org @snippet44
special 0x17F
return
//---------------
#org @snippet45
msgbox @string27 MSG_KEEPOPEN //"I'll be looking forward to seeing\..."
goto @snippet44
//---------------
#org @snippet46
setflag 0x2F4
msgbox @string28 MSG_KEEPOPEN //"Finally[.]\pYou've finally complet..."
goto @snippet44
//---------------
#org @snippet47
msgbox @string29 MSG_KEEPOPEN //"Ah, [player]!\nHow is your POKéDEX..."
additem ITEM_POKEBALL 0x5
loadpointer 0x0 @string14 //"[player] received five POKé BALLS."
giveitem2 ITEM_POKEBALL 0x5 0x101
setflag 0x247
release
end
//---------------
#org @snippet48
fanfare 0x13D
return
//---------------
#org @snippet49
fanfare 0x103
return
//---------
// Strings
//---------
#org @string1
= OAK: Now, [player].\pInside those three POKé BALLS are\nPOKéMON.\pWhich one will you choose for\nyourself?
#org @string2
= Thank you, [player]!\nSincerely, thank you!\lYou've made my dream a reality!
#org @string3
= POKéMON around the world wait for\nyou, [player]!
#org @string4
= OAK: Oh, [player]!\nHow is my old POKéMON?\pWell, it seems to be growing more\nattached to you.\pYou must be talented as a POKéMON\nTRAINER.\pWhat's that?\nYou have something for me?
#org @string5
= [player] delivered OAK'S PARCEL.
#org @string6
= Ah! \nIt's the custom POKé BALL!\pI had it on order.\nThank you!
#org @string7
= [rival]: Gramps!
#org @string8
= [rival]: I almost forgot!\nWhat did you call me for?
#org @string9
= OAK: Oh, right!\nI have a request for you two.
#org @string10
= On the desk there is my invention,\nthe POKéDEX!\pIt automatically records data on\nPOKéMON you've seen or caught.\pIt's a high-tech encyclopedia!
#org @string11
= OAK: [player] and [rival].\nTake these with you.
#org @string12
= [player] received the POKéDEX\nfrom PROF. OAK.
#org @string13
= OAK: You can't get detailed data\non POKéMON by just seeing them.\pYou must catch them to obtain\ncomplete data.\pSo, here are some tools for\ncatching wild POKéMON.
#org @string14
= [player] received five POKé BALLS.
#org @string15
= When a wild POKéMON appears,\nit's fair game.\pJust throw a POKé BALL at it and\ntry to catch it!\pThis won't always work, however.\pA healthy POKéMON can escape.\nYou have to be lucky!
#org @string16
= To make a complete guide on all\nthe POKéMON in the world[.]\pThat was my dream!\pBut, I'm too old.\nI can't get the job done.\pSo, I want you two to fulfill my\ndream for me.\pGet moving, you two.\pThis is a great undertaking in\nPOKéMON history!
#org @string17
= [rival]: All right, Gramps!\nLeave it all to me!
#org @string18
= [player], I hate to say it, but you\nwon't be necessary for this.\pI know! I'll borrow a TOWN MAP\nfrom my sis!\pI'll tell her not to lend you one,\n[player]! Hahaha!\pDon't bother coming around to\nmy place after this!
#org @string19
= OAK: [player], raise your young\nPOKéMON by making it battle.\pIt has to battle for it to grow.
#org @string20
= OAK: If a wild POKéMON appears,\nyour POKéMON can battle it.\pWith it at your side, you should be\nable to reach the next town.
#org @string21
= Wroooooooaaaaaarrrr!
#org @string22
= OAK: Ah, welcome!\pTell me, how is your POKéDEX\ncoming along?\pWahaha!\pActually, I know how it is, but I\nlove seeing it anyway!\pLet's see[.]
#org @string23
= OAK: Good to see you!\nHow is your POKéDEX coming along?\pHere, let me take a look.
#org @string24
= The amount of progress you've made\non your POKéDEX is:\p[buffer1] POKéMON seen and\n[buffer2] POKéMON owned.\p\c\h06ÁPROF. OAK's rating:
#org @string25
= And your NATIONAL POKéDEX is:\p[buffer1] POKéMON seen and\n[buffer2] POKéMON owned.
#org @string26
= OAK: Come see me sometime.\pAfter all, I want to know how your\nPOKéDEX is coming along.
#org @string27
= I'll be looking forward to seeing\nyou fill the NATIONAL POKéDEX!
#org @string28
= Finally[.]\pYou've finally completed the\nPOKéDEX!\pIt's magnificent!\nTruly, this is a fantastic feat!
#org @string29
= Ah, [player]!\nHow is your POKéDEX shaping up?\p[rival] has already caught some\nPOKéMON and added to the data.\pSo, [player], let's have a look at\nyour POKéDEX.\p[.]What's the matter?\nYou've added no new data at all.\pI'll give you these, so do try a\nlittle harder.
//-----------
// Movements
//-----------
#org @move1
#raw 0x62 //Exclamation Mark (!)
#raw 0xFE //End of Movements
#org @move2
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0xFE //End of Movements
#org @move3
#raw 0x2E //Face Up (Delayed)
#raw 0xFE //End of Movements
#org @move4
#raw 0x4A //Face Player
#raw 0xFE //End of Movements
#org @move5
#raw 0x2D //Face Down (Delayed)
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0x1C //Delay5
#raw 0x1B //Delay4
#raw 0x2F //Face Left (Delayed)
#raw 0xFE //End of Movements
#org @move6
#raw 0x11 //Step Up (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0xFE //End of Movements
#org @move7
#raw 0x2D //Face Down (Delayed)
#raw 0xFE //End of Movements
#org @move8
#raw 0x1A //Delay3
#raw 0x2D //Face Down (Delayed)
#raw 0xFE //End of Movements
#org @move9
#raw 0x30 //Face Right (Delayed)
#raw 0xFE //End of Movements
#org @move10
#raw 0x2F //Face Left (Delayed)
#raw 0xFE //End of Movements
#org @move11
#raw 0x11 //Step Up (Normal)
#raw 0x12 //Step Left (Normal)
#raw 0x1C //Delay5
#raw 0x2D //Face Down (Delayed)
#raw 0xFE //End of Movements
#org @move12
#raw 0x12 //Step Left (Normal)
#raw 0x12 //Step Left (Normal)
#raw 0x11 //Step Up (Normal)
#raw 0x1C //Delay5
#raw 0x30 //Face Right (Delayed)
#raw 0xFE //End of Movements
#org @move13
#raw 0x1C //Delay5
#raw 0x1B //Delay4
#raw 0x2F //Face Left (Delayed)
#raw 0xFE //End of Movements
#org @move14
#raw 0x1C //Delay5
#raw 0x1B //Delay4
#raw 0x2E //Face Up (Delayed)
#raw 0xFE //End of Movements
#org @move15
#raw 0x13 //Step Right (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0xFE //End of Movements
#org @move16
#raw 0x10 //Step Down (Normal)
#raw 0x13 //Step Right (Normal)
#raw 0xFE //End of Movements
#org @move17
#raw 0x1C //Delay5
#raw 0x1B //Delay4
#raw 0x30 //Face Right (Delayed)
#raw 0xFE //End of Movements
#org @move18
#raw 0x10 //Step Down (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0x10 //Step Down (Normal)
#raw 0xFE //End of Movements
#org @move19
#raw 0x25 //Step on the Spot Down (Faster)
#raw 0x29 //Step on the Spot Down (Fastest)
#raw 0x25 //Step on the Spot Down (Faster)
#raw 0x25 //Step on the Spot Down (Faster)
#raw 0x29 //Step on the Spot Down (Fastest)
#raw 0x25 //Step on the Spot Down (Faster)
#raw 0xFE //End of Movements
#org @move20
#raw 0x26 //Step on the Spot Up (Faster)
#raw 0x2A //Step on the Spot Up (Fastest)
#raw 0x26 //Step on the Spot Up (Faster)
#raw 0x26 //Step on the Spot Up (Faster)
#raw 0x2A //Step on the Spot Up (Fastest)
#raw 0x26 //Step on the Spot Up (Faster)
#raw 0xFE //End of Movements
#org @move21
#raw 0x27 //Step on the Spot Left (Faster)
#raw 0x2B //Step on the Spot Left (Fastest)
#raw 0x27 //Step on the Spot Left (Faster)
#raw 0x27 //Step on the Spot Left (Faster)
#raw 0x2B //Step on the Spot Left (Fastest)
#raw 0x27 //Step on the Spot Left (Faster)
#raw 0xFE //End of Movements
#org @move22
#raw 0x28 //Step on the Spot Right (Faster)
#raw 0x2C //Step on the Spot Right (Fastest)
#raw 0x28 //Step on the Spot Right (Faster)
#raw 0x28 //Step on the Spot Right (Faster)
#raw 0x2C //Step on the Spot Right (Fastest)
#raw 0x28 //Step on the Spot Right (Faster)
#raw 0xFE //End of Movements
^ thats the amended version for xse