MAZE file format

Applies to:
PSTEE

General Description
This file format is used to randomise the layout of the Modron Maze. It is very similar to the maze structure found within GAM V1.1 for classic PST. A resource of this type can usually only be found inside SAV files after the Modron Maze has been initialized by the game.

Detailed Description
Overall structure


The main structure defines the layout of all maze areas, including special areas such as foyer, engine room or wizard room. By default it is 740h (1856) bytes long.

Offset Size (data type) Description
0x0000 4 (char array) Signature ('MAZE')
0x0004 4 (char array) Version ('V1.0')
0x0008 64 * 28 (array of structs) A 8 x 8 grid of Maze Entries
0x0708 4 (dword) # rows of areas (always 8)
0x070c 4 (dword) # columns of areas (always 8)
0x0710 4 (dword) Wizard room position X
0x0714 4 (dword) Wizard room position Y
0x0718 4 (dword) Nordom's room position X
0x071c 4 (dword) Nordom's room position Y
0x0720 4 (dword) Foyer position X
0x0724 4 (dword) Foyer position Y
0x0728 4 (dword) Engine room position X
0x072c 4 (dword) Engine room position Y
0x0730 4 (dword) Total number of traps
0x0734 4 (dword) Maze initialized (0: no, 1: yes)
0x0738 4 (dword) Foyer maze blocker made (0: no, 1: yes)
0x073c 4 (dword) Foyer engine blocker made (0: no, 1: yes)


This structure defines the individual configuration of a single Modron Maze area. It has 1Ch (28) bytes.

Offset Size (data type) Description
0x0000 4 (dword) Used (0: No, 1: Yes)
0x0004 4 (dword) Accessible (0: No, 1: Yes)
0x0008 4 (dword) Is valid (0: No, 1: Yes)
0x000c 4 (dword) Is trapped (0: No, 1: Yes)
0x0010 4 (dword) Trap type
  • 0: Trap A
  • 1: Trap B
  • 2: Trap C
0x0014 4 (dword) Exits available at
  • Bit 0: East
  • Bit 1: West
  • Bit 2: North
  • Bit 3: South
0x0018 4 (dword) Populated (0: No, 1: Yes)