Pokémon species data structure (Generation IV)

From Bulbapedia, the community-driven Pokémon encyclopedia.
Jump to navigationJump to search

The Pokémon species data structure is a 44-byte structure that determines all information inherent to a Pokémon species, such as base stats, types, Egg Groups, and EV yield. Every Pokémon species in the Generation IV games has a data structure stored in the game's ROM.

Notes

Base Stats
type offset
Base HP byte 0
Base Attack byte 1
Base Defense byte 2
Base Speed byte 3
Base Sp. Attack byte 4
Base Sp. Defense byte 5
Type 1 byte 6
Type 2 byte 7
Catch rate byte 8
Base Exp. yield byte 9
Effort yield word 10
Item 1 word 12
Item 2 word 14
Gender byte 16
Egg cycles byte 17
Base friendship byte 18
Level-up type byte 19
Egg Group 1 byte 20
Egg Group 2 byte 21
Ability 1 byte 22
Ability 2 byte 23
Safari Zone rate byte 24
Color byte 25
Padding* word 26
TM and HM flags 13 bytes 28
Padding* 3 bytes 41

Missing from this structure are moves known at Level 1, level-up moves, and evolutions, which are stored elsewhere.

Types

The types are associated with the following values:

Value Type
0 Normal
1 Fighting
2 Flying
3 Poison
4 Ground
5 Rock
Value Type
6 Bug
7 Ghost
8 Steel
9 ???
10 Fire
11 Water
Value Type
12 Grass
13 Electric
14 Psychic
15 Ice
16 Dragon
17 Dark

If the Pokémon only has one type, both Type 1 and Type 2 will be set to the same value.

Effort yield

Each stat is assigned two bits to determine how many EVs the Pokémon will give in that stat. The last 4 bits in the byte are empty (0).

Bits Stat
0-1 HP
2-3 Attack
4-5 Defense
6-7 Speed
8-9 Special Attack
10-11 Special Defense

Items

If an item is assigned to Item 1, the Pokémon will have a 50% chance of having that item when encountered in the wild. An item assigned to Item 2 will have a 5% chance of being held. If both Item 1 and Item 2 are the same, then the Pokémon will always be holding that item when it is encountered.

Gender

Main article: Personality value → Gender

This value determines the chance that a Pokémon will be male or female. If the species is not all male, all female, or gender unknown, then this value is compared to the lowest byte of a Pokémon's personality value to determine its gender.

Value Gender
0 Always male
1-253 Mixed /
254 Always female
255 Gender unknown

Level-up Type

The following values correspond to the different growth rates a Pokémon can have:

Value Growth Lv100 Exp
0 Medium Fast 1,000,000
1 Erratic 600,000
2 Fluctuating 1,640,000
3 Medium Slow 1,059,860
4 Fast 800,000
5 Slow 1,250,000

Egg Groups

The following values correspond to the different Egg Groups a Pokémon can belong to:

Value Type
1 Monster
2 Water 1
3 Bug
4 Flying
5 Field
Value Type
6 Fairy
7 Grass
8 Human-Like
9 Water 3
10 Mineral
Value Type
11 Amorphous
12 Water 2
13 Ditto
14 Dragon
15 No Eggs Discovered

For Pokémon only in a single Egg Group, both entries are the same value.

Safari Zone rate

This value determines the rate at which the Pokémon will flee when encountered in the Safari Zone. Only Pokémon that appear in the Safari Zone have this value set.

Color

Color is used in the Pokémon Storage System box thumbnails. The following values correspond to the different possible colors:

Value Type
0 Red
1 Blue
2 Yellow
3 Green
4 Black
Value Type
5 Brown
6 Purple
7 Gray
8 White
9 Pink

For some Pokémon species, the bit 7 (the most significant bit) of this field is also 1. The reason for this is unclear.

TMs

The TMs which a Pokémon can learn are stored as a bunch of flags. Starting from the LSB of the first byte, and ending with the MSB of the last byte. The HMs are treated as TMs 93-100. The remaining 4 bits in the last byte are all 0.


Fingerprint

Below is a sample of the data for the first Pokémon species data structures.

00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 // ?????????? (used for unknown/glitch Pokémon)
2D 31 31 2D 41 41 0C 03 2D 40 00 01 00 00 00 00 1F 14 46 03 01 07 41 00 00 03 00 00 20 07 35 84 08 1E 10 02 20 24 66 92 02 00 00 00 // BULBASAUR
3C 3E 3F 3C 50 50 0C 03 2D 8D 00 05 00 00 00 00 1F 14 46 03 01 07 41 00 00 03 00 00 20 07 35 84 08 1E 10 02 20 24 66 92 02 00 00 00 // IVYSAUR
50 52 53 50 64 64 0C 03 2D D0 00 06 00 00 00 00 1F 14 46 03 01 07 41 00 00 03 00 00 30 47 35 86 08 1E 10 02 28 24 66 92 0A 00 00 00 // VENUSAUR
27 34 2B 41 3C 32 0A 0A 2D 41 40 00 00 00 00 00 1F 14 46 03 01 0E 42 00 00 00 00 00 23 06 51 CC E4 1E 82 12 01 A4 46 92 02 00 00 00 // CHARMANDER
3A 40 3A 50 50 41 0A 0A 2D 8E 40 01 00 00 00 00 1F 14 46 03 01 0E 42 00 00 00 00 00 23 06 51 CC E4 1E 82 12 01 A4 46 92 02 00 00 00 // CHARMELEON
4E 54 4E 64 6D 55 0A 02 2D D1 00 03 00 00 00 00 1F 14 46 03 01 0E 42 00 00 00 00 00 33 46 71 CE E4 5E 8E 16 09 A4 46 B2 02 00 00 00 // CHARIZARD
2C 30 41 2B 32 40 0B 0B 2D 42 10 00 00 00 00 00 1F 14 46 03 01 02 43 00 00 01 00 00 65 32 53 CC 40 1E C0 02 00 22 46 C2 07 00 00 00 // SQUIRTLE
3B 3F 50 3A 41 50 0B 0B 2D 8F 10 04 00 00 00 00 1F 14 46 03 01 02 43 00 00 01 00 00 65 32 53 CC 40 1E C0 02 00 22 46 C2 07 00 00 00 // WARTORTLE
4F 53 64 4E 55 69 0B 0B 2D D2 00 0C 00 00 00 00 1F 14 46 03 01 02 43 00 00 01 00 00 75 72 53 CE 40 1E C8 02 88 A2 46 C6 0F 00 00 00 // BLASTOISE
...


Data structure in the Pokémon games
General Character encoding
Generation I Pokémon speciesPokémonPoké MartCharacter encodingSave
Generation II Pokémon speciesPokémonTrainerCharacter encoding (Korean) • Save
Generation III Pokémon species (EvolutionPokédexType chart)
Pokémon (substructures) • MoveContestContest moveItem
Trainer TowerBattle FrontierCharacter encodingSave
Generation IV Pokémon species (EvolutionLearnsets)
PokémonSaveCharacter encoding
Generation V–present Character encoding
Generation VIII Save
TCG GB and GB2 Character encoding


Project Games logo.png This data structure article is part of Project Games, a Bulbapedia project that aims to write comprehensive articles on the Pokémon games.