Class SpawnConditions
- Namespace
- Vintagestory.API.Common.Entities
- Assembly
- VintagestoryAPI.dll
The spawn conditions assigned to various things. Open in GitHub
[DocumentAsJson]
public class SpawnConditions
- Inheritance
-
SpawnConditions
- Inherited Members
- Extension Methods
Examples
"spawnconditions": {
"worldgen": {
"TriesPerChunk": {
"avg": 0.1,
"var": 0
},
"tryOnlySurface": true,
"minLightLevel": 10,
"groupSize": {
"dist": "verynarrowgaussian",
"avg": 3,
"var": 4
},
"insideBlockCodes": [ "air", "tallgrass-*" ],
"minTemp": 5,
"maxTemp": 28,
"minRain": 0.45,
"minForest": 0.35,
"companions": [ "pig-wild-female", "pig-wild-piglet" ]
},
"runtime": {
"group": "neutral",
"tryOnlySurface": true,
"chance": 0.0006,
"maxQuantity": 4,
"minLightLevel": 10,
"groupSize": {
"dist": "verynarrowgaussian",
"avg": 3,
"var": 4
},
"insideBlockCodes": [ "air", "tallgrass-*" ],
"minTemp": 5,
"maxTemp": 28,
"minRain": 0.45,
"minForestOrShrubs": 0.35,
"companions": [ "pig-wild-female", "pig-wild-piglet" ]
}
}
Fields
Climate
Control specific spawn conditions based on climate. Note that this will override any climate values set in Runtime and Worldgen. It is recommended to specify climate values here rather than setting them in the other spawn conditions.
[DocumentAsJson("Recommended", "None", false)]
public ClimateSpawnCondition Climate
Field Value
Runtime
Runtime requirements for the object to spawn.
[DocumentAsJson("Recommended", "None", false)]
public RuntimeSpawnConditions Runtime
Field Value
Worldgen
Worldgen/region requirements for the object to spawn.
[DocumentAsJson("Recommended", "None", false)]
public WorldGenSpawnConditions Worldgen
Field Value
Methods
Clone()
public SpawnConditions Clone()