Format:Build MAP (board file)
| Magic | none (int32 version at offset 0) |
|---|---|
| Extensions | .map |
| Endianness | little |
| On this wiki | Facts · Code · Notes · Topics |
Board file of the Build engine (.MAP): a 4-byte version (7, 8 or, in EDuke32, 9), start position and angle, then counted arrays of 40-byte sectors, 32-byte walls and 44-byte sprites, all little-endian.
Layout
All integers are little-endian. There is no magic number: the first 4 bytes are the map version.
| Offset | Size | Field |
|---|---|---|
| 0 | 4 | version (7 or 8 in the original engine; 9 also accepted by EDuke32 and NBlood) |
| 4 | 12 | start x, y, z (int32 each; z is stored shifted up 4 bits as Ken's note says) |
| 16 | 2 | start angle (0-2047, clockwise) |
| 18 | 2 | start sector number |
| 20 | 2 | numsectors (uint16) |
| 22 | 40 x numsectors | sector array |
| - | 2 | numwalls |
| - | 32 x numwalls | wall array |
| - | 2 | numsprites |
| - | 44 x numsprites | sprite array |
The structs are declared packed in build.h (#pragma pack(1)), so the sizes are those of the field lists in the facts: sector 40, wall 32, sprite 44, matching //sizeof(...) notes in Ken's documentation.
Versions
| Version | Limits (sectors / walls / sprites) | Notes |
|---|---|---|
| 7 | 1024 / 8192 / 4096 | the version Ken's BUILDINF.TXT calls current (7L) |
| 8 | 4096 / 16384 / 16384 | larger limits, same struct layouts |
| 9 | as 8 | EDuke32/NBlood: written when the map uses True Room over Room (YAX) bunches; same struct sizes |
Older editor formats (versions 4, 5, 6) are read by jfbuild's loadboardv4/5/6 with different struct layouts, not covered here.
Code & repositories
- https://github.com/jonof/jfbuild @
e06cbd005a8e6d5f38b5a7aa27ea597dd233c16e· license: LicenseRef-Build-Source-License (declared by the contributor; GitHub's detector did not recognize COPYING)
Jonathon Fowler's port of Ken Silverman's Build engine source: src/engine.c (loadboard, loadpics, loadpalette), src/cache1d.c (GRP) and doc/buildinf.txt (Ken's ART, MAP and PALETTE.DAT notes). The Build source license (buildlic.txt) allows free non-commercial redistribution of derivatives over the Internet; cite facts only.
Tested on: source read, not run: source and BUILDINF.TXT read at the cited commit, not run · checked 2026-10-19; last activity 2026-06-28 - https://github.com/NBlood/NBlood @
497385d64b97f4fd13b6efb3929df0f2ab3adc87· license: none
NBlood: Blood port that carries the EDuke32 Build engine fork (source/build/src engine.cpp, tiles.cpp, palette.cpp) and Blood's RFF Resource class (source/blood/src/resource.cpp). Used for map version 9, the BUILDART prefix, PALETTE.DAT variants and the RFF format.
Tested on: source read, not run: source read at the cited commit, not run · checked 2026-10-19; last activity 2026-10-02; Note: the latest release ships binaries; the wiki links only the source, never the binaries; no license: not reusable
Pitfalls
- The loader of jfbuild returns -2 for any version other than 7 or 8; EDuke32 builds with the small (V7) limits reject version 8.
- Data after the sprite array is ignored; EDuke32 logs a warning about appended data and drops it on save.
- Sprite cstat bits 4-5 equal to 3 are cleared on load by jfbuild (that combination is invalid).
Unverified
Unverified: Blood and Shadow Warrior maps use the same version number field but the engine-level loader above may not apply to Blood's extended board format; check NBlood's source/blood before parsing Blood maps.