Memory map
The game executable · Overlays · Routines · Data · Address index
This page shows how the DOS START.EXE identified in the
file inventory is laid out: which part of
the file is loaded as the program, where its data lives and where the
overlays are stored. Offsets on this page are file offsets unless stated
otherwise; how addresses are written
gives the conversions to analysis addresses and data-segment offsets.
The file at a glance
| File offsets | Size | Contents |
|---|---|---|
0x00000–0x031ff | 0x3200 | MZ header of the DOS executable. |
0x03200–0x3d6cf | 0x3a4d0 | Resident program image, loaded when the game starts: code and the data segment. Analysis addresses 0x10000–0x4a4cf. |
0x3d6d0–0x3d6df | 16 bytes | FBOV overlay header. |
0x3d6e0–0x5146f | 0x13d90 | The thirteen overlay images, contiguous, each followed by its fixups and zero bytes, except the last. |
0x51470–0x5160f | 0x1a0 | The fixups of overlay 256, 0x17e bytes, then 34 zero bytes up to the end of the file. |
The file is 333,328 bytes (0x51610) long.
Inside the resident image
The resident image contains a few structures that the rest of this reference relies on:
| File offset | Analysis address | Contents |
|---|---|---|
0x2d520 | 0x3a320 | Segment table, in 8-byte entries; overlay code reaches resident code and stubs through it. |
0x2dda0–0x2e35f | 0x3aba0–0x3b15f | The thirteen overlay stubs. |
0x2e360 | 0x3b160 | Start of the data segment (DS:0x0000, paragraph 0x3b16), immediately after the stubs. |
0x33e11–0x33e88 | 0x40c11–0x40c88 | The opcode handler table, at DS:0x5ab1. |
The variables and tables of the data segment are listed on the data page; the routines of the resident code on the routines page.
The FBOV header
The overlay area begins with a 16-byte header:
| File offset | Contents |
|---|---|
0x3d6d0 | The four characters FBOV. |
0x3d6d4 | 32-bit little-endian value 0x13f30: the number of bytes from the end of this header to the end of the file. |
0x3d6d8 | Value 0x2d520, equal to the file offset of the segment table. |
0x3d6dc | Value 269: the number of 8-byte entries in the segment table. |
At run time
Where DOS and the overlay manager place the resident image and the overlays in memory is not established. This reference therefore never uses runtime addresses: resident code is located by analysis addresses, overlay code by file offsets, and data by data-segment offsets.