Table of Contents

Class BlockBehaviorUnstableRock

Namespace
Vintagestory.GameContent
Assembly
VSSurvivalMod.dll

Makes a block potentially unstable, but can be held up using support beams. This behavior will only function if the "caveIns" world config is set to true. Uses the code "UnstableRock".

[DocumentAsJson]
[AddDocumentationProperty("UnstableRockStabilization", "The vertical stabilization that this block gives to nearby unstable rock blocks.", "System.Int32", "Optional", "0", true)]
public class BlockBehaviorUnstableRock : BlockBehavior
Inheritance
BlockBehaviorUnstableRock

Examples

Fields

collapseChance (Optional) (Default: 0.25)

If the block is deemed unstable, what is the chance that it will fall? Unconnected blocks will fall regardless.

[DocumentAsJson("Optional", "0.25", false)]
protected float collapseChance

Field Value

float

collapsedBlockLoc (Optional) (Default: None)

If set, then the block will be replaced with this when it begins to fall.

[DocumentAsJson("Optional", "None", false)]
protected AssetLocation collapsedBlockLoc

Field Value

AssetLocation

dustIntensity (Optional) (Default: 1)

The multiplier of dust particles when the block falls.

[DocumentAsJson("Optional", "1", false)]
protected float dustIntensity

Field Value

float

fallSound (Optional) (Default: effect/rockslide)

The sound to play when the block begins to fall.

[DocumentAsJson("Optional", "effect/rockslide", false)]
protected AssetLocation fallSound

Field Value

AssetLocation

impactDamageMul (Optional) (Default: 1)

The damage multiplier when an entity is hit by a falling block. Damage also depends on how far the block has fell.

[DocumentAsJson("Optional", "1", false)]
protected float impactDamageMul

Field Value

float

maxSupportDistance (Optional) (Default: 2)

The distance a support must be for it to support this block.

[DocumentAsJson("Optional", "2", false)]
protected float maxSupportDistance

Field Value

float

maxCollapseDistance (Obsolete)

Currently unused.

[DocumentAsJson("Obsolete", "", false)]
protected float maxCollapseDistance

Field Value

float

Properties

UnstableRockStabilization (Optional) (Default: 0)

The vertical stabilization that this block gives to nearby unstable rock blocks.

Property Value

Int32