SpawnData
<Spawn> elements define a set of spawn actions for creating a set of starting equipment or items, as well as creating prebuilt structures and room atmospheres for tutorials.
XML Structure
<Spawn
Id="string"
Event="string"
HideInStartScreen="boolean"
ShowInSpawnMenu="boolean"
StartScreenHeader="string">
<Name Key="string" />
<Species><!-- SpeciesCondition --></Species>
<Difficulty><!-- DifficultyCondition --></Difficulty>
<SurvivalProperty><!-- SurvivalPropertyAction --></SurvivalProperty>
<Item><!-- DynamicSpawnData --></Item>
<DynamicThing><!-- DynamicSpawnData --></DynamicThing>
<Structure><!-- StructureSpawnData --></Structure>
<WorldAtmosphere><!-- WorldAtmosphereSpawnData --></WorldAtmosphere>
<Spawn><!-- SpawnData --></Spawn>
</Spawn>
Examples
<Spawn Id="PotatoSupplies">
<DynamicThing Id="DynamicCrate">
<Color Id="Green"/>
<Item Id="SeedBag_Potato">
<Quantity Value="3"/>
</Item>
<Item Id="ItemHydroponicTray">
<Quantity Value="5"/>
</Item>
<Item Id="ItemKitPipeUtilityLiquid">
<Quantity Value="1"/>
</Item>
<Item Id="ItemKitPipeLiquid">
<Quantity Value="20"/>
</Item>
</DynamicThing>
</Spawn>
<Spawn Id="EmergencyRespawnHuman">
<Item Id="ItemEmergencySpaceHelmet" SlotId="Helmet"/>
<Item Id="ItemEmergencyEvaSuit" SlotId="Suit">
<Item Id="ItemGasCanisterEmpty" SlotId="AirTank">
<Name Key="SpawnDataOxygenCanister"/>
<Color Id="White"/>
<Gas Type="Oxygen" Moles="150" Celsius="20"/>
</Item>
<Item Id="ItemGasFilterCarbonDioxide" SlotId="Filter"/>
<Item Id="ItemGasCanisterEmpty" SlotId="WasteTank"/>
<Item Id="ItemBatteryCell" SlotId="LifeSupport">
<Charge State="Full"/>
</Item>
</Item>
<Spawn Id="EmergencyToolbelt"/>
</Spawn>
<Spawn Id="EmergencyRespawnHuman" Event="RespawnPlayerKit">
<Species Id="Human"/>
<Difficulty Id="Stationeer" Compare="Equal"/>
</Spawn>
Valid Check
In order to be considered valid, a SpawnData must have at least one of the following children:
<Item><DynamicThing><Spawn><Structure><WorldAtmosphere>
When not valid, this is instead a reference spawn and the Id attribute is used to look up SpawnData defined elsewhere to execute. Reference spawns can still specify all attributes to configure its display in the New World menu and which Event it executes on, as well as <Species> and <Difficulty> conditions to further filter its execution.
Attributes
Id
- When valid, registers this
SpawnDataglobally for others to reference. Otherwise, specifies whatSpawnDatato lookup and execute here.
Event
-
When this
SpawnDatais a top-level child of aStartConditionDataorWorldSettingData, specifies when this spawn should be executed. Otherwise this attribute is ignored.Possible Values
None(default): Don't execute automaticallyNewWorld: Executed once when creating a new worldNewPlayerKit: Executed once for each player to create their equipment when first joining the worldRespawnPlayerKit: Executed once for each player to create their equipment when respawningNewPlayer: Executed once for each player when first joining the world. Spawns items loose in the world near the playerRespawnPlayer: Executed once for each player when respawning. Spawns items loose in the world near the player
HideInStartScreen
- When
true, thisSpawnDatawill not be displayed in the starting items on the New World menu
ShowInSpawnMenu
- When
true, thisSpawnDatawill be available in the creative spawn menu
StartScreenHeader
- The localization key of the subtitle text for this spawn in the New World menu
Child Elements
Name
<Name Key="string" Value="string" />LocalizedStringReference- Name of this
SpawnData. Currently only used as the display name in the creative spawn menu. May be specified by a localizationKeyor a fixedValue
Conditions
<Species>SpeciesCondition<Difficulty>DifficultyCondition- Condition elements that restrict when this spawn will occur
Survival Property
<SurvivalProperty>SurvivalPropertyAction- Sets a survival property (hydration, mood, etc) of the player or spawned entity
Item Spawn
<Item>DynamicSpawnData<DynamicThing>DynamicSpawnData- Items to spawn as part of this
SpawnData
Structure Spawn
<Structure>StructureSpawnData- Structures to spawn as part of this
SpawnData. Primarily used for prebuilt structures in tutorials
Atmosphere
<WorldAtmosphere>WorldAtmosphereSpawnData-
Atmospheres to spawn as part of this
SpawnData. Primarily used to fill rooms with specific gasses in tutorialsStructure
<WorldAtmosphere X="100" Y="200" Z="300" RoomId="1234> <Gas Type="Oxygen" Moles="100" Celsius="20" /> </WorldAtmosphere>X/Y/Z- World grid coordinates of the atmosphere
RoomId- Id of prebuilt
Roomthis atmosphere is a member of <Gas>GasAction(repeated)- A gas to spawn in this atmosphere
Child Spawns
<Spawn>SpawnData-
Child spawn elements to be executed as part of this
SpawnData. These can be fully defined spawns that will be registered globally by theirId(if present), or references to spawns defined elsewhere.
Parent Elements
<GameData>
<Spawn></Spawn>
</GameData>
<GameData>
<StartCondition>
<Spawn></Spawn>
</StartCondition>
<WorldSettings>
<World>
<Spawn></Spawn>
</World>
</WorldSettings>
</GameData>
<Spawn>
<Spawn></Spawn>
<Spawn>
<DynamicThing>
<Spawn></Spawn>
</DynamicThing>
<Structure>
<Spawn></Spawn>
</Structure>