All Pokémon data flows through two structures (Documentation Index
Fetch the complete documentation index at: https://mintlify.com/pret/pokeemerald/llms.txt
Use this file to discover all available pages before exploring further.
BoxMon and Mon) and a unified accessor interface (GetMonData / SetMonData). Understanding this layer is essential for any code that reads or modifies Pokémon attributes.
BoxMon vs Mon
- BoxPokemon (48-byte encrypted)
- Pokemon (party, with computed stats)
struct BoxPokemon is the 80-byte form stored in the PC box and in saved party data. The secure union holds four 12-byte substructs whose order is determined by personality % 24. All fields inside secure are XOR-encrypted with personality ^ otId.Use GetBoxMonData / SetBoxMonData to access box Pokémon without decrypting manually.Substructs
The four substructs hold distinct data groupings, each 12 bytes:| Substruct | Contents |
|---|---|
PokemonSubstruct0 | Species, held item, experience, PP bonuses, friendship |
PokemonSubstruct1 | Moves (4 slots), PP (4 slots) |
PokemonSubstruct2 | HP/Atk/Def/Speed/SpAtk/SpDef EVs; contest stats (Cool/Beauty/Cute/Smart/Tough/Sheen) |
PokemonSubstruct3 | Pokérus, met location, met level, met game, Poké Ball, OT gender, all 6 IVs (5 bits each), isEgg, abilityNum, all contest ribbons, champion/winning/victory ribbons, fateful encounter bit |
GetMonData / SetMonData
All Pokémon attribute access goes throughGetMonData and SetMonData, which handle decryption, substruct routing, and re-encryption automatically.
MON_DATA_* enum
The complete list of property labels accepted byGetMonData / SetMonData (from include/pokemon.h):
Contest stats and ribbons
Contest stats are stored inPokemonSubstruct2. Ribbon ranks (Normal, Super, Hyper, Master) are stored as 3-bit values in PokemonSubstruct3.
| Property | Description |
|---|---|
MON_DATA_COOL | Cool contest stat (0–255) |
MON_DATA_BEAUTY | Beauty contest stat (0–255) |
MON_DATA_CUTE | Cute contest stat (0–255) |
MON_DATA_SMART | Smart contest stat (0–255) |
MON_DATA_TOUGH | Tough contest stat (0–255) |
MON_DATA_SHEEN | Sheen — limits Pokéblock feeding |
MON_DATA_COOL_RIBBON | Highest Cool contest rank achieved |
MON_DATA_BEAUTY_RIBBON | Highest Beauty contest rank achieved |
MON_DATA_CUTE_RIBBON | Highest Cute contest rank achieved |
MON_DATA_SMART_RIBBON | Highest Smart contest rank achieved |
MON_DATA_TOUGH_RIBBON | Highest Tough contest rank achieved |
MON_DATA_CHAMPION_RIBBON | Given when defeating the Champion |
MON_DATA_WINNING_RIBBON | Battle Tower Lv. 50 streak of 56+ |
MON_DATA_VICTORY_RIBBON | Battle Tower Lv. 100 streak of 56+ |
MON_DATA_ARTIST_RIBBON | Master Rank contest with 800+ points; portrait placed in museum |
MON_DATA_EFFORT_RIBBON | Given at Slateport to Pokémon with maximum EVs |
MON_DATA_MARINE_RIBBON | Never distributed |
MON_DATA_LAND_RIBBON | Never distributed |
MON_DATA_SKY_RIBBON | Never distributed |
MON_DATA_COUNTRY_RIBBON | Distributed at Pokémon Festa ‘04 and ‘05 |
MON_DATA_NATIONAL_RIBBON | Given to purified Shadow Pokémon in Colosseum/XD |
MON_DATA_EARTH_RIBBON | Given for clearing Mt. Battle in Colosseum/XD |
MON_DATA_WORLD_RIBBON | Distributed at Pokémon Festa ‘04 and ‘05 (winners) |
Status conditions
STATUS1 — persistent (saved)
STATUS1 — persistent (saved)
MON_DATA_STATUS returns the STATUS1 bitmask from struct Pokemon. This persists between battles.STATUS2 — volatile (in-battle only)
STATUS2 — volatile (in-battle only)
STATUS2 is stored in struct BattlePokemon and tracks volatile in-battle effects. It is not saved in struct Pokemon.