diff --git a/games/satisfactory-vanilla-stable/game.yaml b/games/satisfactory-vanilla-stable/game.yaml index 82a70ce..fe2f801 100644 --- a/games/satisfactory-vanilla-stable/game.yaml +++ b/games/satisfactory-vanilla-stable/game.yaml @@ -2,14 +2,25 @@ # The official dedicated server (Steam app 1690800), installed by the node with anonymous SteamCMD. # Satisfactory keeps its saves under $HOME/.config/Epic/FactoryGame, so HOME is pointed at the server # volume; otherwise they would land in /home/steam and be lost on the next start. +# The server reads no environment variables, so the startup command writes the settings into its +# Game.ini and Engine.ini before every start, and passes the rest as launch options. id: satisfactory-vanilla-stable name: Satisfactory defaultDockerImage: cm2network/steamcmd defaultStartupCommand: >- export HOME=/server; - mkdir -p "$HOME/.steam/sdk64"; + cfg=FactoryGame/Saved/Config/LinuxServer; + mkdir -p "$HOME/.steam/sdk64" "$cfg"; cp -f /home/steam/steamcmd/linux64/steamclient.so "$HOME/.steam/sdk64/" 2>/dev/null; - exec ./FactoryServer.sh -Port=7777 -ReliablePort=8888 -ExternalReliablePort="${EXTERNAL_RELIABLE_PORT:-8888}" -log -unattended + case "${SERVER_STREAMING:-true}" in true|True|1) ss=1;; *) ss=0;; esac; + printf '[/Script/Engine.GameSession]\nMaxPlayers=%s\n' "${MAX_PLAYERS:-4}" > "$cfg/Game.ini"; + printf '[/Script/FactoryGame.FGSaveSession]\nmNumRotatingAutosaves=%s\n\n[/Script/OnlineSubsystemUtils.IpNetDriver]\nNetServerMaxTickRate=%s\nConnectionTimeout=%s\nInitialConnectTimeout=%s\n\n[/Script/Engine.GarbageCollectionSettings]\ngc.MaxObjectsInEditor=%s\ngc.MaxObjectsInGame=%s\n\n[ConsoleVariables]\nwp.Runtime.EnableServerStreaming=%s\n' + "${AUTOSAVE_NUM:-5}" "${MAX_TICK_RATE:-30}" "${CONNECTION_TIMEOUT:-30}" "${CONNECTION_TIMEOUT:-30}" + "${MAX_OBJECTS:-2162688}" "${MAX_OBJECTS:-2162688}" "$ss" > "$cfg/Engine.ini"; + args=(-Port=7777 -ReliablePort=8888 -ExternalReliablePort="${EXTERNAL_RELIABLE_PORT:-8888}" -log -unattended); + case "${DISABLE_SEASONAL_EVENTS:-false}" in true|True|1) args+=(-DisableSeasonalEvents);; esac; + [ -n "${MULTIHOME:-}" ] && args+=(-multihome="$MULTIHOME"); + exec ./FactoryServer.sh "${args[@]}" requiredMemoryMb: 8192 requiredDiskMb: 20480 defaultPorts: @@ -21,6 +32,13 @@ installConfig: appId: "1690800" defaultConfig: MaxPlayers: 4 + AutosaveNum: 5 + MaxTickRate: 30 + ConnectionTimeout: 30 + MaxObjects: 2162688 + ServerStreaming: true + DisableSeasonalEvents: false + Multihome: "" ExternalReliablePort: '{PUBLIC_PORT_8888}' configSchema: $schema: http://json-schema.org/draft-07/schema# @@ -32,6 +50,52 @@ configSchema: type: integer category: Gameplay & Rules default: 4 + AutosaveNum: + title: Autosave Rotation Count + description: How many rotating autosave files to keep in the save folder. + type: integer + minimum: 1 + category: World & Environment + default: 5 + MaxTickRate: + title: Max Tick Rate + description: The highest simulation tick rate the server runs at, in Hz. + type: integer + minimum: 10 + maximum: 120 + category: System & General + default: 30 + ConnectionTimeout: + title: Connection Timeout + description: Seconds before a player who stops responding is disconnected. + type: integer + minimum: 5 + category: System & General + default: 30 + MaxObjects: + title: Max Objects Limit + description: Unreal Engine object limit. Raise it for very large late-game factories. + type: integer + category: World & Environment + default: 2162688 + ServerStreaming: + title: Server Streaming + description: Lets the server stream world data in and out instead of keeping it all loaded. + type: boolean + category: System & General + default: true + DisableSeasonalEvents: + title: Disable Seasonal Events + description: Turns off seasonal events such as FICSMAS. + type: boolean + category: Gameplay & Rules + default: false + Multihome: + title: Multihome Address + description: Bind the server to one IP address instead of all of them. Leave empty unless you know you need it. + type: string + category: System & General + default: "" ExternalReliablePort: title: Reliable Messaging Port (public) description: The port players' games use for reliable messaging. Filled in for you; only change it if you know you need to. @@ -39,18 +103,6 @@ configSchema: category: System & General default: '{PUBLIC_PORT_8888}' required: [] -configFilePath: FactoryGame/Saved/Config/LinuxServer/Game.ini -configFileFormat: STANDARD -configFormatOptions: - header: | - [/Script/Engine.GameSession] - footer: "\n" - separator: "\n" - assignment: '=' - quoteStrings: false - trueValue: "True" - falseValue: "False" - uppercaseKeys: false maxPlayersConfigKey: MaxPlayers logFilePath: FactoryGame/Saved/Logs/FactoryGame.log agnosticCommandConfig: