siir is a SCS/SII file decoder and decompressor written in Zig. It is designed to handle game files from SCS Software, such as Euro Truck Simulator 2 (ETS2) and American Truck Simulator (ATS).
This project provides both a command-line tool (CLI) and a library, allowing for easy integration into other projects.
- Decryption: Support for encrypted files with the
ScsCsignature. - Decompression: Support for zlib compressed data (signatures starting with
0x78). - Binary Decoding: Decodes binary SII files (signature
BSII). - Format Detection: Automatically identifies
3nK,NSii(plain text),ScsC(encrypted), andBSII(binary) formats.
- Zig: Version
0.15.1. - Just (optional): For easier build command execution.
To build the project from source:
# Release build (optimized)
zig build -Doptimize=ReleaseSafe
# Debug build
zig build -Doptimize=Debug# Build release version
just build-release
# Run tests
just test
# Format code
just formatThe final executable will be generated in zig-out/bin/siir and the library in zig-out/lib/.
The CLI allows you to decode files and display the results in the terminal or save them to a file.
# Display help
siir --help
# Decode and print to terminal (stdout)
siir game.sii
# Decode and save to a specific file
siir game.sii -o decoded.sii
# Check version
siir --versionTo ensure the integrity of the decoder, run the unit tests:
zig build test
# or
just test