Table of Contents

Class ClimateSpawnCondition

Namespace
Vintagestory.API.Common.Entities
Assembly
VintagestoryAPI.dll

A list of conditions based on climate. Open in GitHub

[DocumentAsJson]
public class ClimateSpawnCondition
Inheritance
ClimateSpawnCondition
Derived
Inherited Members
Extension Methods

Fields

HabitatSize

If true, will check for suitable habitat size (e.g. when underwater and size of 2 will check that there is also water 2 blocks away in all directions For habitat land: Not implemented yet For habitat air: Not implemented yet

[DocumentAsJson("Optional", "true", false)]
public int HabitatSize

Field Value

int

MapCode

[JsonIgnore]
public string MapCode

Field Value

string

MaxForest

The maximum amount of forest cover needed for the object to spawn.

[DocumentAsJson("Optional", "1", false)]
public float MaxForest

Field Value

float

MaxRain

The maximum amount of rain for the object to spawn.

[DocumentAsJson("Optional", "1", false)]
public float MaxRain

Field Value

float

MaxShrubs

The maximum amount of shrubbery needed for the object to spawn.

[DocumentAsJson("Optional", "1", false)]
public float MaxShrubs

Field Value

float

MaxTemp

The maximum tempurature for the object to spawn.

[DocumentAsJson("Optional", "40", false)]
public float MaxTemp

Field Value

float

MaxY

Won't span above maxY. 0...1 is world bottom to sea level, 1...2 is sea level to world top

[DocumentAsJson("Optional", "2", false)]
public float MaxY

Field Value

float

MinForest

The minimum amount of forest cover needed for the object to spawn.

[DocumentAsJson("Optional", "0", false)]
public float MinForest

Field Value

float

MinForestOrShrubs

The minimum amount of forest or shrubs for the object to spawn.

[DocumentAsJson("Optional", "0", false)]
public float MinForestOrShrubs

Field Value

float

MinRain

The minimum amount of rain for the object to spawn.

[DocumentAsJson("Optional", "0", false)]
public float MinRain

Field Value

float

MinShrubs

The minimum amount of shrubbery needed for the object to spawn.

[DocumentAsJson("Optional", "0", false)]
public float MinShrubs

Field Value

float

MinTemp

The minimum tempurature for the object to spawn.

[DocumentAsJson("Optional", "-40", false)]
public float MinTemp

Field Value

float

MinY

Won't span below minY. 0...1 is world bottom to sea level, 1...2 is sea level to world top

[DocumentAsJson("Optional", "0", false)]
public float MinY

Field Value

float

RandomMapCodePool

If defined, further constrains the spawning areas by a large scale 2D density map

[DocumentAsJson("Optional", "null", false)]
public string[] RandomMapCodePool

Field Value

string[]

Methods

Clone()

public ClimateSpawnCondition Clone()

Returns

ClimateSpawnCondition

MatchesClimate(ClimateCondition)

public bool MatchesClimate(ClimateCondition climate)

Parameters

climate ClimateCondition

Returns

bool

MatchesForestation(ClimateCondition)

public bool MatchesForestation(ClimateCondition climate)

Parameters

climate ClimateCondition

Returns

bool

SetFrom(ClimateSpawnCondition)

public void SetFrom(ClimateSpawnCondition conds)

Parameters

conds ClimateSpawnCondition