Pokemon Ruby/Sapphire - Various Notes
Values derived from a Pokemon's ID
Each Pokemon comes with a 32 bit identifier, generated at random, which determines significant information about the uniqueness of the Pokemon.
Nature
The ID modulo 25 identifies the nature of a Pokemon. Shown here are the taste preferences of Pokemon with those natures (what PokeBlocks they like), and the stats to increase and decrease.
| Hex | Nature | Like | Dislike | Stat increase | Stat decrease |
|---|---|---|---|---|---|
| 00 | Hardy | (neutral) | |||
| 01 | Lonely | Spicy | Sour | +Attack | -Defense |
| 02 | Brave | Spicy | Sweet | +Attack | -Speed |
| 03 | Adamant | Spicy | Dry | +Attack | -Special Attack |
| 04 | Naughty | Spicy | Bitter | +Attack | -Special Defense |
| 05 | Bold | Sour | Spicy | +Defense | -Attack |
| 06 | Docile | (neutral) | |||
| 07 | Relaxed | Sour | Sweet | +Defense | -Speed |
| 08 | Impish | Sour | Dry | +Defense | -Special Attack |
| 09 | Lax | Sour | Bitter | +Defense | -Special Defense |
| 0A | Timid | Sweet | Spicy | +Speed | -Attack |
| 0B | Hasty | Sweet | Sour | +Speed | -Defense |
| 0C | Serious | (neutral) | |||
| 0D | Jolly | Sweet | Dry | +Speed | -Special Attack |
| 0E | Naive | Sweet | Bitter | +Speed | -Special Defense |
| 0F | Modest | Dry | Spicy | +Special Attack | -Attack |
| 10 | Mild | Dry | Sour | +Special Attack | -Defense |
| 11 | Quiet | Dry | Sweet | +Special Attack | -Speed |
| 12 | Bashful | (neutral) | |||
| 13 | Rash | Dry | Bitter | +Special Attack | -Special Defense |
| 14 | Calm | Bitter | Spicy | +Special Defense | -Attack |
| 15 | Gentle | Bitter | Sour | +Special Defense | -Defense |
| 16 | Sassy | Bitter | Sweet | +Special Defense | -Speed |
| 17 | Careful | Bitter | Dry | +Special Defense | -Special Attack |
| 18 | Quirky | (neutral) |
Gender
| If Pokemon species is... | Range of female |
|---|---|
| 12.5% female | 0-30 |
| 25% female | 0-63 |
| 50% female | 0-126 |
| 75% female | 0-190 |
Unown shape
A=(id>>24)&0x03; B=(id>>16)&0x03; C=(id>>8 )&0x03; D=(id )&0x03; Unown=D|(C<<2)|(B<<4)|(A<<6);The lowest 5 bits of the resulting byte contains the Unown shape.
Wurmple
If the remainder of Wurmple's ID divided by 10 is greater than or equal to 5, it will evolve into Cascoon; else Silcoon.
Individual Values
Finding Individual Values
These formulas are not directly used in the game, as the Individual Values of a Pokemon are already available to it and hidden from view. Thus these formulas can only approximate the IVs of a Pokemon and are therefore for information only.
IV = ((ceil(S/PV)-5)*100/L)-2*B-floor(EV/4)
where:- ceil(X) = round up
- floor(X) = round down
- S = Stat (not the HP stat, which has a similar formula, see below)
- PV = Personality, derived from the Pokemon's nature
- L = Level
- B = Pokemon's base stat
- EV = Effort value for stat
HP IV = ((S-L-10)*100/L)-2*B-floor(EV/4)
The PV depends on the Pokemon's nature: it is initially equal to 1.
If the nature increases the stat by 10%, the PV is 1.1.If the nature decreases the stat by 10%, the PV is 0.9.
Effort Values
The Effort Values or EVs, indicate the amount of training that a Pokemon has made. Whenever a foe Pokemon is defeated in an internal battle (wild or trainer), each Pokemon that participated in the battle against it will earn a number of EVs depending on the species of the Pokemon defeated. The limit that a Pokemon can earn is 510. A Pokemon can earn up to 255 EVs per stat (HP, Attack, Defense, Speed, Special Attack, Special Defense). A Pokemon begins with Effort Values of 0 for all stats. According to the stat formula (above), for a level 100 Pokemon, every 4 EVs increase the corresponding stat by 1.
The stat enhancers (HP Up, Protein, Iron, Carbos, Calcium, and Zinc, respectively) increase the EVs of the respective stat by 10. Each stat enhancer only takes effect if the EV for that stat is less than 100. After a stat enhancer is used and takes effect, the Pokemon's stats are recalculated. (Stat enhancers are also known as "vitamins".)
In the Emerald version, certain Berries can decrease a Pokemon's effort values by 10 (Pomeg Berry, Kelpsy Berry, Qualot Berry, Tamato Berry, Hondew Berry, and Grepa Berry, respectively).
The Macho Brace and the PokeRus virus each will double the EVs that a Pokemon will earn.
If a Pokemon is holding an Exp. Share, it will earn EVs as though it were one of the battle's participants. (If it has the PokeRus virus, its EV gain is doubled as usual.)
When your Pokemon has earned the maximum of 510 EVs, it can receive an Effort Ribbon in Slateport's outdoor market.
Rare Candy, like other methods of level gain, uses the Effort Values in stat calculation, contrary to rumors.
Effort Values are not obtained in battle when a Pokemon reaches level 100.
Stats
The game uses these formulas to find a Pokemon's stats. A Pokemon's stats are calculated whenever it gains a level or when the player encounters or receives it.
HP = int(int(A*2+B+int(C/4))*D/100)+D+10
Other Stats = int((int(int(A*2+B+int(C/4))*D/100)+5)*E)
where:
- A = Pokemon's Base Stat
- B = Pokemon's Individual Value
- C = Pokemon's Effort Value
- D = Pokemon's Level
- E = Normally equal to 1.
If the Pokemon's nature decreases the stat by 10%, E = (90/100).
As an exception, Shedinja's HP is always 1 (its Base HP is 1).
Encounters
This section applies to the Ruby and Sapphire versions.
Each area has a probability of Pokemon appearing, expressed as a value of 1, 4, 9, 10, 20, 25, 30, and 35. Whenever the player takes a step in which Pokemon could appear, the game uses this formula:
X = Y * 16
where:
- Y = Encounter value
- If a random number from 0 to 2874 exclusive is less than X, a Pokemon will appear.
Modifications
- If the Mach Bike or Acro Bike is used, multiply by 4/5.
- If the Black Flute had been used, multiply by 1/2. If the White Flute had been used, multiply by 3/2.
- If the first Pokemon in party has a Cleanse Tag, multiply by 2/3.
- If the first Pokemon in party has Stench, multiply by 1/2. If the first Pokemon in party has Illuminate, multiply by 2/3. (In either case, ignore if the Pokemon holds a Cleanse Tag.)
Experience
Whenever a Pokemon defeats another Pokemon, it gains Experience points (EXP). The amount of EXP a Pokemon is worth is based on a formula shown below.
Formula used if no Pokemon in party is holding an Exp. Share:
Experience = int(int(L*G/7)/E)*X*Y*Z
Formula used if at least one unfainted Pokemon in party is holding an Exp. Share:
Experience = (int(M/E)*A+int(M/F)*B)*X*Y*Z
where:
- L = Defeated Pokemon's level
- G = Defeated Pokemon's Base Experience
- X = If the battle is a Trainer battle, X=1.5; else 1.
- Y = If the participating Pokemon's ID is different from the player's ID, Y=1.5; else 1 ("[name] gained a boosted [value] Exp. Points!")
- Z = If the participating Pokemon is holding a Lucky Egg, Z=1.5; else 1.
- M = int(int(L*G/7)/2)
- E = Number of unfainted Pokemon that participated in the battle against the defeated Pokemon
- F = Number of unfainted Pokemon that are holding an Exp. Share
- A = If the Pokemon participated in the battle against the defeated Pokemon, A=1; else 0.
- B = If the participating Pokemon is holding an Exp. Share, B=1; else 0.
Eggs and fainted Pokemon don't count as participants in a battle.
When a Pokemon gains a level, its current HP is its new HP minus the HP lost before the level gain.
After entrusting a Pokemon to the Day Care, it will earn 1 Exp. Point for each step the player walks.
Two growth rates were added in Ruby and Sapphire: their maximum experience values are 600,000 and 1,640,000.
See the Experience table.
Trainer ID
Shiny Pokemon
Shininess is based on the personality ID and the 32-bit trainer ID:
A = PersonalityID XOR TrainerID B = A AND 0xFFFF C = (A >> 16) AND 0xFFFF D = B XOR C SHINY = (D < 8)
Notes on breeding
Egg Waiting Time
X depends on the species and trainer ID of the Pokemon:
- Same species, different ID: X=70
- Same species, same ID: X=50
- Different species, different ID: X=50
- Different species, same ID: X=20
Every 256 steps after the two Pokemon are placed in the daycare, an egg will be ready if a random number from 0 through 99 is less than X. The baby will be calculated as soon as the egg is received.
Species
- One of the Pokemon can be a Ditto, but not both. The baby will be the species that isn't the Ditto, in the lowest stage. For the purposes of breeding, the Ditto will have the gender that the other isn't.
- The species hatched from a Nidoran(f) is either Nidoran(m) or Nidoran(f).
- The species hatched from an Illumise is either Illumise or Volbeat.
- If neither parent is holding a Lax Incense and the baby species would be Wynaut, the baby species is Wobbuffet instead.
- If neither parent is holding a Sea Incense and the baby species would be Azurill, the baby species is Marill instead.
Ability
Moves
The baby initially has all moves it would have at level 5. The baby can inherit other moves from its parents, in this order:
- The baby will inherit a move if the father knows it and it's an egg move for the baby's species.
- The baby will inherit a move if the father knows it and it can be taught to the baby's species through a TM or HM.
- The baby will inherit a move if both the mother and father know it and the baby's species could learn it by leveling up.
- In the Emerald version, if the father is a Pikachu and holds a Light Ball and the baby is a Pichu, the baby will learn Volt Tackle.
Individual Values
The baby inherits three Individual Values corresponding to a different stat from among HP, Attack, Defense, Speed, Special Attack, and Special Defense. Each of these Individual Values is inherited from either the mother or father.
Except in the Emerald version, however, the same stat can be chosen again because the last stat chosen before is overwritten in the process of choosing three random stats.
Personality ID
Except in the Emerald version, the two low-order bytes of the baby's personality ID are never both equal to 0.
Nature
A random nature is chosen for the baby, indirectly through generation of a personality ID.
As an exception, in the Emerald version, there is a (32767/65536) chance that the baby will gain the nature of the holder of Everstone if that holder is a Ditto or the baby's mother. This case is handled by recalculating the baby's personality ID up to 2400 times until the nature is the same and the personality ID's high-order 2 bytes do not equal 0.