File Type Reference¶
The ZenGin uses a lot of custom file formats to store game data like meshes, animations and textures. Originally these custom formats for specifically made with Direct3D and later DirectX in mind and are thus sometimes confusing to understand or use some old, proprietary APIs common at the time. One example of this is DirectMusic which is used or the in-game music.
All files used by the ZenGin are binary files with the little-endian byte order or text files encoded with the Windows-1252 character set.
1st-party formats¶
The following is a list of file types and formats used by ZenGin.
Format | Extension | Description | ZenKit Class Name |
---|---|---|---|
Model Animation | .MAN |
Contains animations for a model | ModelAnimation |
Model Hierarchy | .MDH |
Contains skeletal information for a model | ModelHierarchy |
Model Mesh | .MDM |
Contains the mesh of a model | ModelMesh |
Model | .MDL |
Contains a mesh and a hierarchy which make up a model | Model |
Morph Mesh | .MMB |
Contains a morph mesh with its mesh, skeleton and animation data | MorphMesh |
Multi Resolution Mesh | .MRM |
Contains a mesh with LOD information | MultiResolutionMesh |
Mesh | .MSH |
Contains mesh vertices and vertex features like materials | Mesh |
Daedalus Script | .DAT |
Contains a compiled Daedalus script | DaedalusScript |
Texture | .TEX |
Contains texture data in a variety of formats | Texture |
Font | .FNT |
Contains font data | Font |
ZenGin Archive | .ZEN |
Contains various structured data (general object persistence). | ReadArchive |
Text/Cutscenes | .BIN , .CSL , .DAT , .LSC |
Contains text and cutscene data | CutsceneLibrary |
Model Script | .MDS , .MSB |
Contains model animation script data and associated hierarchy and mesh information | ModelScript |
Virtual File System | .VDF |
Contains a directory structure containing multiple files; similar to TAR. | Vfs |
3rd-party formats¶
The ZenGin uses the following 3rd-party file formats:
- DirectMusic for the soundtrack
- DXT1, DXT3 and DXT5 for texture compression
- WAV for speech and sound effects
- TGA for uncompressed images
- Bink for cutscene videos
For all of these, Open Source parsers are available, however some of them are no longer maintained. For DirectMusic there is libdmusic (unmaintained), for DXT decompression there is libsquish (unmaintained), stb can also decompress DXT-compressed files and can read in TGA files and the amazing ffmpeg can decode Bink video.