C# Class CaveworldFlora.GenClusterPlantReproduction

GenClusterPlantReproduction class.
Datei anzeigen Open project: Rikiki123456789/Rimworld Class Usage Examples

Public Methods

Method Description
IsClusterAreaClear ( ThingDef_ClusterPlant plantDef, int newDesiredClusterSize, IntVec3 position ) : bool

Check if there is another cluster too close.

IsValidPositionToGrowPlant ( ThingDef_ClusterPlant plantDef, IntVec3 position, bool checkTemperature = true ) : bool

Check if position is valid to grow a plant. Does not check cluster exclusivity!

TryGetRandomClusterSpawnCell ( ThingDef_ClusterPlant plantDef, int newDesiredClusterSize, bool checkTemperature, IntVec3 &spawnCell ) : void

Try to get a valid cell to spawn a new cluster anywhere on the map.

TryGetRandomSpawnCellAwayFromCluster ( Cluster cluster, int newDesiredClusterSize, IntVec3 &spawnCell ) : void

Try to get a valid cell to spawn a new cluster away from plant.

TryGetRandomSpawnCellNearCluster ( Cluster cluster, IntVec3 &spawnCell ) : void

Get a valid cell in this cluster to spawn another cave plant.

TryGrowCluster ( Cluster cluster ) : ClusterPlant

Try to spawn another plant in this cluster.

TrySpawnNewClusterAwayFrom ( Cluster cluster ) : ClusterPlant

Try to spawn a new cluster away from plant.

TryToReproduce ( ClusterPlant plant ) : ClusterPlant

Try to spawn another cave plant in the cluster or to spawn a new cluster.

TryToSpawnNewSymbiosisCluster ( Cluster cluster ) : ClusterPlant

Method Details

IsClusterAreaClear() public static method

Check if there is another cluster too close.
public static IsClusterAreaClear ( ThingDef_ClusterPlant plantDef, int newDesiredClusterSize, IntVec3 position ) : bool
plantDef ThingDef_ClusterPlant
newDesiredClusterSize int
position IntVec3
return bool

IsValidPositionToGrowPlant() public static method

Check if position is valid to grow a plant. Does not check cluster exclusivity!
public static IsValidPositionToGrowPlant ( ThingDef_ClusterPlant plantDef, IntVec3 position, bool checkTemperature = true ) : bool
plantDef ThingDef_ClusterPlant
position IntVec3
checkTemperature bool
return bool

TryGetRandomClusterSpawnCell() public static method

Try to get a valid cell to spawn a new cluster anywhere on the map.
public static TryGetRandomClusterSpawnCell ( ThingDef_ClusterPlant plantDef, int newDesiredClusterSize, bool checkTemperature, IntVec3 &spawnCell ) : void
plantDef ThingDef_ClusterPlant
newDesiredClusterSize int
checkTemperature bool
spawnCell IntVec3
return void

TryGetRandomSpawnCellAwayFromCluster() public static method

Try to get a valid cell to spawn a new cluster away from plant.
public static TryGetRandomSpawnCellAwayFromCluster ( Cluster cluster, int newDesiredClusterSize, IntVec3 &spawnCell ) : void
cluster Cluster
newDesiredClusterSize int
spawnCell IntVec3
return void

TryGetRandomSpawnCellNearCluster() public static method

Get a valid cell in this cluster to spawn another cave plant.
public static TryGetRandomSpawnCellNearCluster ( Cluster cluster, IntVec3 &spawnCell ) : void
cluster Cluster
spawnCell IntVec3
return void

TryGrowCluster() public static method

Try to spawn another plant in this cluster.
public static TryGrowCluster ( Cluster cluster ) : ClusterPlant
cluster Cluster
return ClusterPlant

TrySpawnNewClusterAwayFrom() public static method

Try to spawn a new cluster away from plant.
public static TrySpawnNewClusterAwayFrom ( Cluster cluster ) : ClusterPlant
cluster Cluster
return ClusterPlant

TryToReproduce() public static method

Try to spawn another cave plant in the cluster or to spawn a new cluster.
public static TryToReproduce ( ClusterPlant plant ) : ClusterPlant
plant ClusterPlant
return ClusterPlant

TryToSpawnNewSymbiosisCluster() public static method

public static TryToSpawnNewSymbiosisCluster ( Cluster cluster ) : ClusterPlant
cluster Cluster
return ClusterPlant