https://github.com/aoemods/zig-essence
Zig impl of Relic Entertainment's Essence formats
https://github.com/aoemods/zig-essence
aoe4 zig zig-package
Last synced: 11 months ago
JSON representation
Zig impl of Relic Entertainment's Essence formats
- Host: GitHub
- URL: https://github.com/aoemods/zig-essence
- Owner: aoemods
- License: mit
- Created: 2021-11-25T00:57:22.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-07-26T11:22:10.000Z (almost 4 years ago)
- Last Synced: 2025-07-21T22:30:42.065Z (11 months ago)
- Topics: aoe4, zig, zig-package
- Language: Zig
- Homepage:
- Size: 37.1 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# zig-essence
Low-level minimal allocation implementation of Relic's funky formats in Zig with comments and clearly named variables.
SGAs: Headers should work for all versions of SGAs, but more high-level code and complex operations are only tested on AoE4 SGAs.
## Getting sgatool
You can grab a copy of `sgatool`, the actually executable portion of `zig-essence`, from the latest successful CI run, the latest release (soon), or by compiling the program yourself.
### Compiling
First, install [Zig](https://ziglang.org/). Then:
```bash
git clone https://github.com/aoemods/zig-sga
cd zig-sga
zig build
# Output in ./zig-out/bin!
# Or to run it right away (useful for developers)
zig build sgatool -- [args]
```
## Using as a Library
See `tools/sgatool.zig` and `build.zig` for an example of how `zig-essence` can be used as a library in Zig!
## Prior Art
Credit where credit's due!
Thanks Janne for the [awesome blog post](https://janne252.dev/content/2021/coh3-pre-alpha-extract-sga) as well as the [SGA viewer tooling](https://github.com/Janne252/essence-archive-viewer) that inspired this effort. A dozen lines of documentation are based off of a table in Janne's blog post. \<3
## License
MIT
All files in `dump` are also MIT licensed and generated by other SGA tools. Please do not add any official game archives to `dump`!