Difference between revisions of "Map matrix"

From ProjectPokemon Wiki
Jump to: navigation, search
m
Line 49: Line 49:
  
 
The value of B is the map value, that is, the value of the index of the map (where 411 is Twinleaf Town in DPPt and 60 is New Bark Town in HGSS).
 
The value of B is the map value, that is, the value of the index of the map (where 411 is Twinleaf Town in DPPt and 60 is New Bark Town in HGSS).
 +
 +
[[Category:Technical References]]
 +
[[Category:Structures]]

Revision as of 13:09, 30 April 2010

The map_matrix contains the data that associates the graphically generated maps to the map values.

File location

Pokemon DPPt- root/fielddata/mapmatrix/map_matrix.narc

Pokemon HGSS- root/a/0/4/1

Data Structure

Data Offset Size Description
0x00 Uint8 Width of Global Map
0x01 Uint8 Height of Global Map
0x04 Uint8 Number of Characters of Map Prefix
0x05 Char* Map Prefix Name
Next UInt16** Data

* Length determined by 0x04

** Length of data is Height X Width

Data In Use

Let Height = 3, Width = 3, Data = ABCDEFGHI, Map Prefix = ExMap (so prefix length is 5)

[[A B C]
 [D E F]
 [G H I]]

This illustrates that the value at B goes with the map named ExMap00_01c because B is (0,1) in the above matrix. The map names are declared within the proper land_data[_release] files.

The value of B is the map value, that is, the value of the index of the map (where 411 is Twinleaf Town in DPPt and 60 is New Bark Town in HGSS).