Spawn CLI
Spawn commands inspect and convert ALife .spawn files. Unpack a file for editing, then rebuild and verify a separate
output before replacing the game’s spawn file.
Examples
Run from a working directory containing all.spawn, with new output paths:
xrf-cli spawn info --path ./all.spawn
xrf-cli spawn unpack --path ./all.spawn --dest ./all_spawn
Example output excerpt — inspect spawn data:
Spawn file information:
Version: 10
GUID: a117405b-0a2e-a781-4ab5-f7aa88ae759c
Levels count: 5
Objects count: 262
Artefact spawn points: 256
Patrols: 4636
Level version: 10
Level graph vertices: 934
Level graph points: 512
Level graph edges: 2568
Exit code: 0.
info reports the header and counts of objects, artifact spawns, patrols, and graph entries. After editing the exported
representation:
xrf-cli spawn pack --path ./all_spawn --dest ./all.rebuilt.spawn
xrf-cli spawn verify --path ./all.rebuilt.spawn
Verification reads the packed file and checks that its structure can be parsed. Use gamedata verification for checks involving the surrounding assets; test the affected spawning behavior in game.
Re-serialize a spawn file
xrf-cli spawn repack --path ./all.spawn --dest ./all.repacked.spawn
repack reads a packed file and writes another packed file. It does not automatically compare the output with the
source or prove that an editing workflow preserved behavior.
Failure notes
Every command that writes requires --dest. Packing and unpacking reject existing destinations unless --force is
supplied. Choose a new destination while reviewing edits; use --force when replacing that output is intended.
If the source cannot be parsed, inspect the reported chunk or format error before editing. Repacking requires a readable source and does not repair truncated data.
Command reference
xrf-cli spawn info
Print what a spawn file holds
xrf-cli spawn info [OPTIONS] --path <path>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Path to spawn file | |
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |
xrf-cli spawn pack
Pack an unpacked spawn file folder into one *.spawn
xrf-cli spawn pack [OPTIONS] --path <path> --dest <dest>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Unpacked spawn file folder | |
-d, --dest <dest> | yes | Packed *.spawn written | |
-f, --force | Replace the destination when it is already there, once the new one is ready | ||
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |
xrf-cli spawn repack
Read a *.spawn and write it packed again
xrf-cli spawn repack [OPTIONS] --path <path> --dest <dest>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Packed *.spawn | |
-d, --dest <dest> | yes | Repacked *.spawn written | |
-f, --force | Replace the destination when it is already there, once the new one is ready | ||
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |
xrf-cli spawn re-unpack
Read an unpacked spawn file folder and write it unpacked again
xrf-cli spawn re-unpack [OPTIONS] --path <path> --dest <dest>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Unpacked spawn file folder | |
-d, --dest <dest> | yes | Folder the re-unpacked spawn file is written to | |
-f, --force | Replace the destination when it is already there, once the new one is ready | ||
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |
xrf-cli spawn unpack
Unpack a *.spawn into a folder of text files
xrf-cli spawn unpack [OPTIONS] --path <path> --dest <dest>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Packed *.spawn | |
-d, --dest <dest> | yes | Folder the unpacked spawn file is written to | |
-f, --force | Replace the destination when it is already there, once the new one is ready | ||
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |
xrf-cli spawn verify
Verify that a *.spawn reads
xrf-cli spawn verify [OPTIONS] --path <path>
| Option | Required | Default | Description |
|---|---|---|---|
-p, --path <path> | yes | Packed *.spawn, or its unpacked folder with –unpacked | |
-u, --unpacked | Read the path as an unpacked spawn file folder | ||
-s, --silent | Turn off logging | ||
-v, --verbose | Turn on verbose logging | ||
--json | Write the run’s JSON report to stdout, moving human output to stderr | ||
--report <PATH> | Write the run’s JSON report to a file |