Essentials Docs Wiki
Advertisement
For Poké Center nurses that heal Pokémon, see Poké Center.
For NPCs that sell items, see Poké Mart.
For the Day Care Couple, see Day Care.

This page describes how to set up special NPCs. These include Move Tutors, Move Deleters, Move Relearners and Pokémon Nicknamers.

Move Tutor

Pokémon games have one or more NPCs that can teach a certain move to some Pokémon. The simplest form of this NPC is as follows:

@>Conditional Branch: Script: pbMoveTutorChoose(:SOFTBOILED)
  @>Text: Move learned.
  @>
 : Else
  @>Text: Move not learned.
  @>
 : Branch End
@>

You will also need to define which moves a Pokémon can be learn via Move Tutor. To do so, open the PBS file "pokemon.txt" and change the "TutorMoves" defined for a species.

You can have a Move Tutor teach more than one move, by having the player first choose which move they want to teach. Some Move Tutors require a payment in order to teach a move.

See the page Learning moves for more information on how move-learning works.

Move Deleter

The Move Deleter can make a Pokémon forget any moves a Pokémon knows, including HM moves. It cannot delete a move if it is the only one the Pokémon knows.

There is an example of a Move Deleter in the example maps. The general layout of the Move Deleter's event is as follows:

  1. Ask whether the player wants to delete a move.
  2. The player chooses a Pokémon in their party.
    • Make sure a Pokémon was chosen (i.e. the choice wasn't cancelled), and that it can forget a move (i.e. isn't an eggShadow Pokémon or only knows 1 move).
  3. Choose a known move to delete.
  4. Ask if the player is sure.
  5. Delete the move.

Move Relearner

The Move Relearner is an alternate form of the Move Tutor. This NPC is able to teach any Pokémon any move that appears in its moveset (but only those which can be learned before the Pokémon's current level).

Move Relearners typically require payment, usually a Heart Scale, in order to make a Pokémon relearn a move.

There is an example of a Move Relearner in the example maps. The general layout of the Move Relearner's event is as follows:

  1. Check whether the player can afford the payment (a Heart Scale). It is not paid yet, though.
  2. Ask whether the player wants to make a Pokémon relearn a move.
  3. The player chooses a Pokémon in their party.
    • Make sure there is at least one move that Pokémon can relearn, and that it can relearn a move (i.e. isn't an egg or Shadow Pokémon).
  4. Choose a move to relearn.
  5. Relearn the move, and make the payment if successful.

Name Rater

The Name Rater (or Pokémon Nicknamer) allows the player to nickname (or remove the nickname of) any of their Pokémon. Only Pokémon that were originally owned by the player can have their nicknames changed.

There is an example of a Name Rater in the example maps. The general layout of the Name Rater's event is as follows:

  1. Ask whether the player wants a Pokémon's name rated.
  2. The player chooses a Pokémon in their party.
    • Make sure a Pokémon was chosen (i.e. the choice wasn't cancelled), and that its name can be rated (i.e. isn't an egg or Shadow Pokémon).
  3. Check whether the Pokémon was originally owned by the player - if it wasn't, its nickname is "too good to change".
  4. Ask whether the player wants to rename the Pokémon.
  5. The player provides a new name.
    • If the new name is blank or the same as the Pokémon's species name, remove the nickname.
    • If the new name is a nickname, give it to the Pokémon.

Fossil reviver

The Fossil Reviver is an NPC, usually a scientist, who will take a fossil from the player and turn it into a Pokémon depending on the type of fossil.

There is an example of a Fossil Reviver in the example maps. It is a variation on a time-sensitive event, and will therefore have 3 event pages: the first is the introduction, the second is the result, and the third is the "intermediate" stage. Each page is outlined below.

There is also an example in the example maps of a Fossil Reviver who combines two fossils into a single Pokémon. This will not be described here.

The Fossil Reviver uses a Game Variable, which stores the ID of the species being revived. It also uses a Game Switch, which is ON while the reviving is taking place - this Game Switch is typically turned OFF in the door event leading to the Fossil Reviver's room (i.e. the player has to step outside and back in to get their Pokémon). Because of this, it behaves much like a time-sensitive event except it depends on a Game Switch being turned OFF at a fixed point rather than checking for elapsed time.

Page 1

This is the introduction page, where the Fossil Reviver asks for a fossil.

  1. Use the method pbChoosefosil(9) to let the player choose a fossil to hand over. 9 is the number of the Game Variable used by the Fossil Reiviver.
    • The item's ID is saved in the Game Variable used by the Fossil Reviver (or :NONE if the choice was cancelled).
    • This method can be used even if the player has no fossils; in which case it won't show/say anything, and will store a result of :NONE.
  2. Delete 1 of the chosen item from the player's Bag.
  3. Convert the item's ID into a Pokémon species ID using the below code.
  4. Set the "revival in progress" Game Switch ON, and set the Fossil Reviver's Self Switch to go to the second page.
conversion_hash = {
  :HELIXFOSSIL => :OMANYTE,
  :DOMEFOSSIL  => :KABUTO,
  :OLDAMBER    => :AERODACTYL,
  :ROOTFOSSIL  => :LILEEP,
  :CLAWFOSSIL  => :ANORITH,
  :SKULLFOSSIL => :CRANIDOS,
  :ARMORFOSSIL => :SHIELDON
}
item = pbGet(9)
species = conversion_hash[item]
pbSet(9, species)

The hash lists pairs of a fossil and its corresponding species. The code below it gets the item from Game Variable 9 and stores the corresponding species into that Game Variable.

Page 2

This is the result page, where the Fossil Reviver hands over the revived Pokémon. It depends on the event's Self Switch being ON (it doesn't matter which one, so long as you're consistent).

  1. Give the player a Pokémon whose species is stored in the Game Variable mentioned above, and whose level is 1.
  2. Set the Fossil Reviver's Self Switch OFF to go to the first page.

Page 3

This is the "intermediate" page, which simply tells the player that revival is in progress. It depends on the "revival in progress" Game Switch being ON.

Apricorn Converter (Kurt)

The Apricorn Converter is very similar to the Fossil Reviver in what it does. It takes an Apricorn from the player and turns it into a Poké Ball item depending on which Apricorn was provided.

The differences are:

  • The Apricorn Converter is a different kind of time-sensitive event, which waits for 24 hours before providing the resulting Poké Ball.
  • The script to choose an Apricorn item is pbChooseApricorn(8), where 8 is the Game Variable in which the ID of the chosen item is stored.
  • The chosen item's ID (Apricorn) is turned into a different item's ID (Poké Ball), rather than into a species' ID.

Everything else behaves the same.

Advertisement