Skip to content

Format: MAP level blocks

Robert Jordan edited this page Oct 8, 2021 · 8 revisions

Format: MAP level blocks

TODO

File format

Byte Order: Little Endian

MAP Header

Off/Len Type Value Description
0,4 char[4] "MAP " File signature
4,4 uint32 FileSize Total size of file - 8
8,4 uint32 Width Level dimensions width
c,4 uint32 Height Level dimensions height
10,2N uint16[w*h] Blocks Grid of block values

MAP Block

A block value is always a 2-byte word. Many map types may truncate away the high byte.

CryOre (cror.map)

Config: CryOreMap ‍ file\path\to.map [:modifier]

No Spawn: 0000

# Crystal Lv0 Ore Lv0 Crystal Lv1 Ore Lv1
1 0001 0002 0003 0004
3 0005 0006 0007 0008
5 0009 000a 000b 000c
10 000d 000e 000f 0010
25 0011 0012 0013 0014
# CryLv0 OreLv0 CryLv1 OreLv1
1 0001 0002 0003 0004
3 0005 0006 0007 0008
5 0009 000a 000b 000c
10 000d 000e 000f 0010
25 0011 0012 0013 0014

Predug (dugg.map)

Config: PredugMap ‍ file\path\to.map [:modifier]

Wall: 0000

Wall 0000
Type Exposed Hidden
Cavern 0001 0002
Slug Hole 0003 0004

Emerge (emrg.map/emer.map)

Config: EmergeMap ‍ file\path\to.map

No Emerge: 0000

ID Trigger Emerge1 Emerge2 Emerge3 Emerge4 Emerge5
0 0001 0002 0003 0004 0005 0006
1 0007 0008 0009 000a 000b 000c
2 000d 000e 000f 0010 0011 0012
3 0013 0014 0015 0016 0017 0018
... +0x6 +0x6 +0x6 +0x6 +0x6 +0x6

Erode (erod.map)

Config: ErodeMap ‍ file\path\to.map

No Erosion: 0000

Speed Adjacent Lava Always
V.Slow 0001 0002
Slow 0003 0004
Medium 0005 0006
Fast 0007 0008
V.Fast 0009 000a

Unintended values

TODO: Confirm speed/limitations/caps

Speed - Reverse
V.Slow 000b 000c
Slow 000d 000e
Medium 000f 0010
Fast 0011 0012
V.Fast 0013 0014

Fallin (fall.map)

Config: FallinMap ‍ file\path\to.map

No Fallin: 0000

Unknown Low Medium High V.High
FlagOff 0001 0002 0003 0004
FlagOn 0005 0006 0007 0008

Path (path.map)

Config: PathMap ‍ file\path\to.map [:modifier]

No Path: 0000

Type
Rubble 0001
Power Path 0002

Terrain (surf.map)

Config: TerrainMap ‍ file\path\to.map [:modifier]

None: 0000

Type
Immovable Wall 0001
Hard Wall 0002
Medium Wall 0003
"Loose" Wall 0004
Soil Wall 0005
Lava 0006
"Water" 0007
Ore Seam 0008
Lake 0009
Crystal Seam 000a
Recharge Seam 000b