mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-03-07 20:31:51 +09:00
66 lines
1.5 KiB
Plaintext
66 lines
1.5 KiB
Plaintext
Terrarum Game Map Format
|
|
|
|
* Endianness: LITTLE
|
|
|
|
Ord Hex Description
|
|
00 54 T
|
|
01 45 E
|
|
02 4D M
|
|
03 7A z # 'z' because it's compressed
|
|
|
|
04 01 Version revision number
|
|
|
|
05 03 Number of layers
|
|
|
|
06 00 Reserved
|
|
07 00 Reserved
|
|
|
|
08 World width
|
|
09 World width
|
|
0A World width
|
|
0B World width
|
|
|
|
0C World height
|
|
0D World height
|
|
0E World height
|
|
0F World height
|
|
|
|
10 Default spawn coord X
|
|
11 Default spawn coord X
|
|
12 Default spawn coord X
|
|
13 Default spawn coord X
|
|
|
|
14 Default spawn coord Y
|
|
15 Default spawn coord Y
|
|
16 Default spawn coord Y
|
|
17 Default spawn coord Y
|
|
|
|
# Layer count 1
|
|
18 54 T
|
|
19 45 E
|
|
20 52 R
|
|
21 52 R
|
|
|
|
22 Uncompressed size of DEFLATEd payload
|
|
23 Uncompressed size of DEFLATEd payload
|
|
24 Uncompressed size of DEFLATEd payload
|
|
25 Uncompressed size of DEFLATEd payload
|
|
|
|
26... DEFLATEd payload for the terrain (MSB ++ LSB; uncompressed size must be 1.5x of MSB) # ++ is a list concat sign in Haskell
|
|
|
|
# Layer count 2
|
|
... "WALL"
|
|
... Uncompressed size of DEFLATEd payload
|
|
... DEFLATEd payload for the wall (MSB ++ LSB; uncompressed size must be 1.5x of MSB)
|
|
|
|
|
|
# Layer count 3
|
|
... "WIRE"
|
|
... Uncompressed size of DEFLATEd payload
|
|
... Wire tiles data (MSB only)
|
|
|
|
<EOF>
|
|
|
|
|
|
* To read layers: you'll need to search for specific strings, namely ["TERR", "WALL", "WIRE"]
|