Z Robot Database Format

From ModdingWiki
Jump to navigation Jump to search

ROBOTS.DAT holds unit definitions and class data used by Z.

File format

The file is a 25000-byte (0x61a8) memory image loaded to the allocated robot-data buffer. It is not the live unit table. Multi-byte fields used by the port are little-endian.

Offset Data type Name Description
0 records of 0x2c bytes entries Definition entries addressed as base + index*0x2c.
0x4650 records of 0x52 bytes types Type records; roster scanning checks the first name byte for zero.
type + 0x1c UINT16LE[21] slots Definition indices; 0xffff means unused.
entry + 0x22 UINT8 class Class index; 0xff means no class.
0x55f0 records of 0x2a bytes classes Class descriptors; +1 is compared when choosing the highest available descriptor.

Notes

Table extents and all definition fields are not fully specified by this summary. Preserve unlabelled bytes. The original applies language-specific patches in memory; the English path does not need them.

Source code

From re-z, the open-source browser port:

Credits

This file format was reverse engineered by VorticonCmdr. If you find this information helpful in a project you're working on, please give credit where credit is due. (A link back to this wiki would be nice too!)