DAT Format (ZZT)
ZZT will search its own directory first when looking for a particular file. If the file can't be found there, it will look inside ZZT.DAT. This allows for game modification without actually modifying any of the original files.
|0||0x000||INT16LE||Number of files in the archive|
|2||0x002||fileName||Start of the file name list|
|1226||0x4CA||INT32LE||Start of the file offset list|
There are 24 file names. ZZT will read through them until it encounters a zero-length string. That's how it determines that it has reached the end of the file list.
|+0||UINT8||Length of the file name|
|+1||char||File name, with padding|
There is nothing to indicate the actual stored length of the files. Therefore, it's important to know how to parse the format of the file that is being requested in order to know when the file actually ends.