-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Speedy Nurse Joy
Alonso edited this page May 2, 2022
·
4 revisions
This tutorial edits the receptionist in the Pokemon Center so that you automatically get healed when you talk to her, and so that you face away from her afterwards. Thanks to TheXaman on Pokecommunity for the code!
In data/scripts/pkmn_center_nurse.inc:
Common_EventScript_PkmnCenterNurse::
lock
faceplayer
setvar VAR_0x8004, 0
specialvar VAR_RESULT, CountPlayerTrainerStars
compare VAR_RESULT, 4
goto_if_eq EventScript_PkmnCenterNurse_GoldCard
- msgbox gText_WouldYouLikeToRestYourPkmn, MSGBOX_YESNO
- compare VAR_RESULT, YES
- goto_if_eq EventScript_PkmnCenterNurse_HealPkmn
- compare VAR_RESULT, NO
- goto_if_eq EventScript_PkmnCenterNurse_Goodbye
+ goto EventScript_PkmnCenterNurse_HealPkmn
end
...
@ VAR_0x8004 is 1 when player has Gold Card
EventScript_PkmnCenterNurse_ReturnPkmn::
compare VAR_0x8004, 1
goto_if_eq EventScript_PkmnCenterNurse_ReturnPkmn2
message gText_RestoredPkmnToFullHealth
waitmessage
applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow
waitmovement 0
message gText_WeHopeToSeeYouAgain
+ goto EventScript_PkmnCenterNurse_PlayerTurn
return
...
EventScript_PkmnCenterNurse_ReturnPkmn2::
message gText_ThankYouForWaiting
waitmessage
applymovement VAR_0x800B, Movement_PkmnCenterNurse_Bow
waitmovement 0
message gText_WeHopeToSeeYouAgain2
+ goto EventScript_PkmnCenterNurse_PlayerTurn
return
At the bottom of the file, add this script. If you're interested, this just makes the player faceaway after healing their mon. If you're observant, you'll also notice that this is the code for the calls we just added to EventScript_PkmnCenterNurse_ReturnPkmn2 and EventScript_PkmnCenterNurse_ReturnPkmn
+ EventScript_PkmnCenterNurse_PlayerTurn::
+ closemessage
+ applymovement OBJ_EVENT_ID_PLAYER, Common_Movement_FaceDown
+ waitmovement 0
+ release
+ end
Congrats! You're done!