Skip to content

SatisfactoryTools/world-data-generator-wrapper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

world-data-generator

CLI microservice for Satisfactory Tools: generates the list of Satisfactory resource nodes (type, purity, location) for a given world seed and randomization settings, as JSON.

Wraps the MIT-licensed randomization algorithm from Konsl/satisfactory-world-generator, which replicates the in-game node randomization introduced in Satisfactory 1.2. The GPL-licensed viewer part of that project is not used (it is disabled via the gui feature).

Usage

world-data-generator --seed <SEED> [-m <MODE>] [-p <PURITY>] [-w <default-world.json>] [--pretty] [-o <FILE>]
  • --seed — world seed as entered in-game (i32)
  • -m, --modenone (default), random, basic-rich, advanced-rich, fossil-fuel-rich
  • -p, --purityno-change (default), all-impure, decrease, all-normal, increase, all-pure, all-random
  • -w, --world-file — path to default-world.json (default: ./default-world.json, or env DEFAULT_WORLD_FILE)

Output (stdout, or -o file):

{
  "gameVersion": "1.2.3.1",
  "seed": 12345,
  "mode": "basic-rich",
  "puritySettings": "no-change",
  "resourceNodes": [
    { "name": "BP_ResourceNode123", "resource": "Desc_OreIron_C", "purity": "normal", "location": [100.0, 200.0, 30.0] }
  ],
  "geysers": [
    { "name": "BP_Geyser1", "purity": "pure", "location": [50.0, 60.0, 700.0] }
  ],
  "frackingCores": [
    {
      "name": "BP_FrackingCore1", "resource": "Desc_Water_C", "location": [2000.0, 2000.0, 0.0],
      "satellites": [ { "name": "BP_FrackingSatellite1", "purity": "normal", "location": [2100.0, 2000.0, 0.0] } ]
    }
  ]
}

Locations are UE world coordinates in centimeters. Resources are the game's descriptor class names (Desc_*_C), purities are impure / normal / pure.

Build

cargo build --release
# -> target/release/world-data-generator

The algorithm comes from the SatisfactoryTools fork of Konsl/satisfactory-world-generator (branch sftools, which exposes it as a GUI-free library), pulled by cargo as a git dependency. For local algorithm development, check the fork out as a sibling directory and switch to the path dependency commented in Cargo.toml.

default-world.json

The default world node data is extracted from game assets and is intentionally not committed. Place it next to the binary (or point --world-file / DEFAULT_WORLD_FILE at it).

A .NET tool that can regenerate it from a game install after a game update lives in assets-extractor/world-extractor-net (currently untested — see its README).

License

MIT. The vendored algorithm is MIT-licensed by its upstream author; the upstream viewer (GPL v3) is not linked into this binary.

About

Wrapper for world data generator

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages