Skip to main content

A plugin to read/write Relic SGA (V2) archive files.

Project description

Relic Tool - SGA - V2

PyPI PyPI - Python Version PyPI - License linting: pylint Checked with mypy Code style: black Pytest Pylint MyPy

Disclaimer

Not affiliated with Sega, Relic Entertainment, or THQ.

Description

A plugin to read/write Relic SGA (V2) archive files.

Game Support

A non-exhaustive list of Games that use Relic's SGA V2

  • Dawn Of War Gold
  • Dawn Of War: Winter Assault
  • Dawn Of War: Dark Crusade
  • Dawn Of War: Soulstorm
  • Impossible Creatures

Installation (Pip)

Installing from PyPI (Recommended)

pip install relic-tool-sga-v2

Installing from GitHub

For more information, see pip VCS support

pip install git+https://github.com/MAK-Relic-Tool/SGA-V2

CLI Commands

Unpacking Archives

This plugin allows SGA-Core to properly unpack SGA-V2 files.

Packing Archives

Converts a .arciv-like file into a .sga archive file.

relic sga v2 pack manifest [out_path]
usage: relic sga v2 pack [-h] [--log [LOG]] [--loglevel [{none,debug,info,warning,error,critical}]] [--logconfig [LOGCONFIG]] manifest [out_path]

positional arguments:
  manifest              An .arciv file (or a suitable .json matching the .arciv tree). If the file extension is not '.json' or '.arciv', '.arciv' is assumed
  out_path              The path to the output SGA file. If the path is a directory, the SGA will be placed in the directory using the name specified in the manifest. If not specified, defaults to the manifest's directory.

options:
  -h, --help            show this help message and exit
  --log [LOG]           Path to the log file, if one is generated
  --loglevel [{none,debug,info,warning,error,critical}]
                        Verbosity of the log. Defaults to `info`
  --logconfig [LOGCONFIG]
                        Path to a logging config file.

Unpacking Archives

Unpacks an .sga archive into a file tree.

relic sga unpack src_sga out_dir
usage: relic sga unpack [-h] [-m | -i] [--log [LOG]] [--loglevel [{none,debug,info,warning,error,critical}]] [--logconfig [LOGCONFIG]] src_sga out_dir

Unpack an SGA archive to the filesystem. If only one root is present in the SGA, '--merge' is implied. If multiple roots are in the SGA '--isolate' is implied. Manually specify the flags to override this behaviour.

positional arguments:
  src_sga               Source SGA File
  out_dir               Output Directory

options:
  -h, --help            show this help message and exit
  -m, --merge           SGA roots will always write to the same folder; specified by out_dir
  -i, --isolate         SGA roots will always write to separate folders, one per alias; located within out_dir
  --log [LOG]           Path to the log file, if one is generated
  --loglevel [{none,debug,info,warning,error,critical}]
                        Verbosity of the log. Defaults to `info`
  --logconfig [LOGCONFIG]
                        Path to a logging config file.

Verifying Archives

Checks the MD5 Hashes and/or the SGS File's CRCs

Useful for verifying if file's have been modified or corrupted.

SGA archives may still be used in-game even if they fail verification

relic sga v2 verify sga_file
usage: relic sga v2 verify [-h] [--all] [-H] [-D] [-F] [-q] [-e] [--tree] [--log [LOG]] [--loglevel [{none,debug,info,warning,error,critical}]] [--logconfig [LOGCONFIG]] sga_file

positional arguments:
  sga_file                   Input SGA File

options:
  -h, --help            show this help message and exit
  --all                 Shorthand for '-H -D -F', if no flags are specified, '--all' is implied
  -H, --header          Verify the SGA Header's MD5 hash
  -D, --data            Verify SGA Data's MD5 hash
  -F, --files           Verify SGA Files's CRC32 hashes
  -q, --quiet           Only print failures and errors
  -e, --error           Stop on first failure or error
  --tree                Prints the SGA File's results in a tree format, if '-q' is specified, folders will still be printed
  --log [LOG]           Path to the log file, if one is generated
  --loglevel [{none,debug,info,warning,error,critical}]
                        Verbosity of the log. Defaults to `info`
  --logconfig [LOGCONFIG]
                        Path to a logging config file.

Report A Bug / Issue

Visit the Issue Tracker

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

relic_tool_sga_v2-2.1.0.tar.gz (59.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

relic_tool_sga_v2-2.1.0-py3-none-any.whl (55.1 kB view details)

Uploaded Python 3

File details

Details for the file relic_tool_sga_v2-2.1.0.tar.gz.

File metadata

  • Download URL: relic_tool_sga_v2-2.1.0.tar.gz
  • Upload date:
  • Size: 59.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for relic_tool_sga_v2-2.1.0.tar.gz
Algorithm Hash digest
SHA256 49683962501b5976bf31ea841fed4fed61861cf2df2b9de0b5482e2cc937f73c
MD5 826f16b3988838781dbccc05c2cc2862
BLAKE2b-256 87dfedfd8438d2ecebd907c8bdd7376b3b155f2a9240cbf401cfe9cb6dd883b0

See more details on using hashes here.

Provenance

The following attestation bundles were made for relic_tool_sga_v2-2.1.0.tar.gz:

Publisher: publish-pypi.yml on MAK-Relic-Tool/SGA-V2

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file relic_tool_sga_v2-2.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for relic_tool_sga_v2-2.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2e1cafca2762cbe04fe847f65fc349325d25f932f0b261dc2df6f18ab8fa683e
MD5 1105bfc753e8faaa87ebcccede950dc3
BLAKE2b-256 740471bd9cf0ff1b3dc3f220531ce2bae64ab0c261caf06310153c8093b4043f

See more details on using hashes here.

Provenance

The following attestation bundles were made for relic_tool_sga_v2-2.1.0-py3-none-any.whl:

Publisher: publish-pypi.yml on MAK-Relic-Tool/SGA-V2

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page