m_level.bin File Format

From ProjectPokemon Wiki
Revision as of 00:12, 3 February 2017 by UniqueGeek (talk | contribs)
Jump to navigation Jump to search



The "/BALANCE/m_level.bin" file in Pokemon Mystery Dungeon: Explorers of Sky/Time/Darkness contains level-up data for all the Pokemon in the game. Its a pack file containing one entry per Pokemon. The index/order of the entry for each Pokemon is identical to the order of the entries in the monster.md file, and that's how they're assigned. However, in Explorers of Sky, the m_level.bin file's number of entries was cut in half, removing most redundant entries.(see monster.md for more details on why its redundant )

Notes
  • Explorers of Sky: Contains 571 entries.
  • Explorers of Time/Darkness: Contains 1,192 entries.
  • The stats the Pokemon has on level 1 are contained within its entry inside the monster.md file! Not in m_level.bin! What is in m_level.bin is merely added to those stats as the Pokemon grows in level.

File Structure

See the pack file page, for details on how the container is organized. This page will focus on the particularities of the content, not the container.

Content Structure

Each individual entry/sub-file is a PKDPX compressed container. Once decompressed, the data is simply 100, 12 bytes entries one after the other. Each of those entries contains the total experience required to reach this level, and the stats growth after the level has been reached.

Level-Up Data List

Here's the structure of the entire thing:

Total length 1200 bytes
Offset Length Type Name Description
0x00 12 FirstLvlEntry Entry for the first level. Its always completely null, since there are no previous levels, and thus, no level-up requirements.
.. Rest of the levels entries here..
0x4A4 12 LastLvlEntry The entry for level 100 !

Level-Up Data Entry

Here's how a single entry for a single level is structured. Everything is little endian.

Total length 12 bytes
Offset Length Type Name Description
0x0 4 int32 ExpReq The total amount of experience required to reach that level. The value is absolute, not relative to the last level!
0x4 2 uint16 HP Increase The amount of HPs the Pokemon will gain when reaching this level.
0x6 1 uint8 Attack Increase The amount the attack of the Pokemon will increase when reaching this level.
0x7 1 uint8 Special Attack Increase The amount the special attack of the Pokemon will increase when reaching this level.
0x8 1 uint8 Defense Increase The amount the defense of the Pokemon will increase when reaching this level.
0x9 1 uint8 Special Defense Increase The amount the special defense of the Pokemon will increase when reaching this level.
0xA 2 uint16 Null 2 bytes of zeroes.