mirror of https://github.com/pret/pokecrystal.git
32 lines
700 B
NASM
32 lines
700 B
NASM
|
TalkToTrainerScript:: ; 0xbe66a
|
||
|
faceplayer
|
||
|
trainerflagaction CHECK_FLAG
|
||
|
iftrue AlreadyBeatenTrainerScript
|
||
|
loadmemtrainer
|
||
|
encountermusic
|
||
|
jump StartBattleWithMapTrainerScript
|
||
|
|
||
|
SeenByTrainerScript:: ; 0xbe675
|
||
|
loadmemtrainer
|
||
|
encountermusic
|
||
|
showemote EMOTE_SHOCK, LAST_TALKED, 30
|
||
|
callasm TrainerWalkToPlayer
|
||
|
applymovement2 MovementBuffer
|
||
|
writepersonxy LAST_TALKED
|
||
|
faceperson PLAYER, LAST_TALKED
|
||
|
jump StartBattleWithMapTrainerScript
|
||
|
|
||
|
StartBattleWithMapTrainerScript: ; 0xbe68a
|
||
|
opentext
|
||
|
trainertext $0
|
||
|
waitbutton
|
||
|
closetext
|
||
|
loadmemtrainer
|
||
|
startbattle
|
||
|
reloadmapafterbattle
|
||
|
trainerflagaction SET_FLAG
|
||
|
loadvar wRunningTrainerBattleScript, -1
|
||
|
|
||
|
AlreadyBeatenTrainerScript:
|
||
|
scripttalkafter
|