Library for parsing files from IdTech 2 (Quake 1/2), GoldSource (Half-Life) and Source (Half-Life 2) engine.
Can be used as Command-line program, see Commands.md.
Goal of this project is to learn, test and document.
- Learn = get to know how others approached the problem before, what decisions they made and how it shaped further development.
- Test = write a code that can interpret the data, see whenever it can be done easier today, validate files.
- Document = write documentation for others and "share the knowledge" (as did people before this project).
| Name | License | Version |
|---|---|---|
| GLM | MIT | branch: master |
| stb | MIT / Public Domain | branch: master |
All libraries are used as static library to maximize optimization and limit problems with deployment and versions.
File formats are documented here.
Supported engines:
- IdTech 2 (Quake / Quake 2)
- MAP
- GoldSrc (Half-Life)
- BSP v30
- MAP
- WAD v3
- RMF
- FGD (backwards compatible)
- Source (Half-Life 2)
- FGD
Compilation tested using GCC and MinGW, C++20 support required.
Look into tests directory for different usages.
GoldSrc tests expect half-life directory (the one containing valve, cstrike, platform...) in project directory (same as lib, src...).
It is recommended to keep it where it is and use Symbolic link.
Enabled by default, set(DECAY_LIBRARY_CMD=OFF) in your CMakeLists.txt to disable.
For list of commands, see Commands.md.
Inside linux directory, there are MIME type definitions for supported BSP and WAD files for KDE.
They recommend having only 1 .xml file per application but several are used sor simplicity.
| MIME | Definition File | File type |
|---|---|---|
application/goldsrc-bsp30 |
goldsrc-bsp30.xml |
BSP version 30 |
application/goldsrc-fgd |
goldsrc-fgd.xml |
FGD (entity definition) |
application/goldsrc-map |
goldsrc-map.xml |
In-development map (text) |
application/goldsrc-rmf |
goldsrc-rmf.xml |
In-development map (binary) |
application/goldsrc-wad2 |
goldsrc-wad2.xml |
WAD 2 - textures, images, fonts |
application/goldsrc-wad3 |
goldsrc-wad3.xml |
WAD 3 - textures, images, fonts |
*-bsp30 and *-wad* have weight 80 (same as application/x-doom) but are defined by file headers.
Decay Library does not support and is not supported by any game engine.
C API was removed due to too many missing features, last commit was 9a3b8aeea4d6b3b7c100e0a5f308406da621a6d1.