This article describes the Pokédex.
See also Edit
- For how Pokémon species are assigned Pokédex numbers, as well as all the displayed information in their entry pages.
- For how to have more than one Pokédex list (even just regional/National versions).
The Pokédex Edit
The Pokédex is an electronic encyclopaedia that the player may be given during their journey. It displays various information about Pokémon species, including elemental types, typical sizes and locations they can be found in the wild.
To give the player the Pokédex, use the following script:
Once gained, an option called "Pokédex" will appear in the Pause menu (but only if there is at least 1 seen species in the Dex list).
There are two arrays associated with the Pokédex:
Both arrays have a length equal to the number of species defined in the PBS file "pokemon.txt", and each entry is either TRUE if the species with that National Dex number has been seen/owned, and FALSE if it hasn't. For example,
$Trainer.seen will be TRUE if the player has seen a Pikachu, and FALSE if they haven't.
The table below contains other functions that relate to the Pokédex:
|Function||What it does|
| || Returns the total number of Pokémon that the player has seen in the specified Regional Dex (or National Dex if the parameter is blank or |
| || Returns the total number of Pokémon that the player has owned in the specified Regional Dex (or National Dex if the parameter is blank or |
| ||Completely erases all information about seen and owned Pokémon, as well as seem forms of Pokémon.|
Regional Dex list screen Edit
This screen shows the available Regional/National Dexes that the player can view. This screen is only accessible if there is more than one available Dex list to choose from - see the article Multiple regions for more details.
List screen Edit
The list screen, pictured above, displays a list of Pokémon species. Next to each of them is an icon which shows whether that species has been seen or owned. If a species has not been seen, then its entry will simply be a line of dashes.
The Seen and Owned numbers relate to the Dex list currently being viewed, and also to any search that may be being carried out.
The name of the Dex currently being viewed is displayed at the top of the screen (default: "Pokédex"). If there is a search being carried out, this name will be amended to indicate this.
Search screen Edit
It is possible to perform a number of searches and filters on the Dex currently being viewed. Searches are temporary, and are ended upon exiting the Pokédex (or earlier), but the "Sort" option persist until changed to something else.
The kinds of searches and sorts available are self-explanatory.
Entry screens Edit
There are three entry pages for each species: Info, Area, and Forms.
Info page Edit
The info page displays various pieces of information about a Pokémon species. Its contents are displayed almost entirely by the def
pbChangeToDexEntry. Some information is only displayed if the player has owned that species. Obviously, this page is only accessible if the species has been seen.
The height and weight are shown in metres and kilograms respectively by default. However, if the game detects that the player is in the United States of America, these values will be converted to feet/inches and stones/pounds respectively.
When a Pokémon has been captured, and its information added to the Pokédex, this page will be shown. There is only one difference here: the page can only be cancelled (i.e. "Back"), and the other two pages are inaccessible. The top bar has a different appearance to show this.
Area page Edit
The area page shows where a Pokémon species can be found in the wild (i.e. their nests).
The nest screen is a copy of the region map screen, changed a little to suit its purpose. The scripts that display the next map are in the script section PokemonNestAndForm.
The map shown in this screen can depend on which Dex is being viewed, if there are multiple Dexes defined. If not, then the map is simply that of the region the player is currently in.
Forms page Edit
The forms page shows all the forms of a species. This includes both gender differences and proper multiple forms. It does not show shiny versions of the sprites.
By pressing the "Use" key, a list will appear, containing all the available forms to view.
- "Male" and "Female" versions of the first (default) form are always available (excepting inappropriate ones such as "Female" for a male-only species). If the species is genderless, then there will just be a "Genderless" option instead.
- The alternate forms are only listed once each, unless one of those forms also has gender differences, in which case both will be available.
The scripts that display the forms screen are in the script section PokemonNestAndForm.
By default, this page will only allow the player to view forms that they have seen. However, in the script section Settings there is the value
ALWAYSSHOWALLFORMS, which if TRUE, will always show all the forms of a species in this page regardless of which ones the player has actually seen.
Recording seen forms Edit
When a Pokémon is encountered in a battle, evolves, hatches, changes its form or is obtained in some way, its combination of species, gender and form are recorded as having been seen by the player. It is recorded by using either of the following two methods:
In the first method, "
poke" is a Pokémon (e.g.
$Trainer.party is the first Pokémon in the party). In the second method, the three parameters are the species, gender (0 or 1) and form respectively. For genderless species, use a gender of 0.
You can use this method on its own. You should use it whenever you manually add a new species as seen to the Pokédex, as at least one form of a seen species must also be seen in order for it to work properly.
The ways in which a Pokémon can be obtained are listed in the article Manipulating Pokémon. These methods have a parameter which decides whether to record the newly-generated Pokémon's form as being seen (default: TRUE). If you want to change a Pokémon's gender or form immediately after giving it to the player, you will need to make sure that parameter is FALSE when giving it, then make the changes, then use
pbSeenForm as described above to make sure only the intended form is recorded.