Json block behaviors UnstableFalling
From Vintage Story Wiki
Purpose
This behavior turns the block into an attachment block that can be attached to any face listed in the attachableFaces
property. If the attachment is later rejected, or if sideways falling is enabled, the block will start falling as a BlockFalling block entity. This is different from the Unstable behavior that drops the block when it loses attachment.
Used by blocks
- anvil
- anvilpart
- barrel
- barrelcactus
- bloomerychimney
- bonyremains
- bonysoil
- carcass
- chair
- chandelier
- cheese
- churn
- clayplanter
- coalpile
- dirtygravel
- displaycase
- drycarcass
- egg
- flowerpot
- gravel
- groundstorage
- ingotmold
- knappingsurface
- lightningrod
- looseboulders
- looseflints
- loosegears
- looseores
- loosestick
- loosestones
- lootvessel
- metal
- metalpartpile
- muddygravel
- oillamp
- omoktabletop
- pan
- pie
- quern
- sand
- seashell
- sieve
- sludgygravel
- snowlayer
- stonecoffinlid
- storagevessel
- table
- talldisplaycase
- toolmold
- wateringcan
- woodbucket
Properties
attachableFaces
(array of face codes, default : ["down"])- The faces of the attachment block that allow attachment. Effectively "down" is always included in the array, no matter what the property specifies. Although there is a bug where the "up" attachment area is used for the always included "down" attachment face (where the "down" attachment area should be used instead).
attachmentArea
(RotatableCube)- If the
attachmentAreas
property is missing, then this property is used for the attachment area of the "up" face. Arguably this is a bug where it should be used it for the "down" face instead. attachmentAreas
(facing code -> RotatableCube)- The attachment area (part of the parent block that should be solid) for each face that the block can attach to. When an attachment is considered for a face of the attachment block, and that face is missing from the map, then a null attachment area will be given to the parent block. Most parent blocks ignore the attachment area when deciding whether to accept an attachment.
ignorePlaceTest
(bool, default: false)- Whether the attachment logic should be skipped when deciding whether the block can be placed at a location. The attachment logic is still used when a neighbor block is changed to consider whether the block should fall.
exceptions
(array of block codes)- The block can be place on top of these blocks, even if all of the neighbor blocks reject the attachment, and the
allowUnstablePlacement
attribute is set to false. This allows the quern to be placed on top of an up-down axle, even though the axle rejects being a parent block. fallSideways
(bool, default: false)- Allows the block to fall sideways, instead of just vertically. The block can fall sideways if a horizontal neighbor is replaceable, and the block below that neighbor is also replaceable. fallSideways also allows the block to fall even if it is attached on some side. This even means that a block that has fallSideways enabled and fallSidewaysChance set to 0 can fall vertically even when it is attached.
fallSidewaysChance
(bool, default: 0.3)- Chance of trying to fall sideways whenever a neighbor block is changed.
fallSound
: (path from sounds folder)- Sound to play while falling.
dustIntensity
(float, default: 0)- Adjusts the amount of dust particles that are generated when the block falls. 0 means no dust particles, and 1 means the same amount of dust as falling sand.
impactDamageMul
(float, default: 1)- When this block lands, any entities in the way receive 18 damage times the fall distance times this impactDamageMul. So higher values increase the damage that the falling block causes to entities.
Block attributes
allowUnstablePlacement
- Allows the block to be placed in a location without attachments, which causes it to immediately fall. This is used by sand and gravel.
Wondering where some links have gone?
The modding navbox is going through some changes! Check out Navigation Box Updates for more info and help finding specific pages.
Modding | |
---|---|
Modding Introduction | Getting Started • Theme Pack |
Content Modding | Content Mods • Developing a Content Mod • Basic Tutorials • Intermediate Tutorials • Advanced Tutorials • Content Mod Concepts |
Code Modding | Code Mods • Setting up your Development Environment |
Property Overview | Item • Entity • Block • Block Behaviors • Block Classes • Block Entities • Block Entity Behaviors • World properties |
Workflows & Infrastructure | Modding Efficiency Tips • Mod-engine compatibility • Mod Extensibility • VS Engine |
Additional Resources | Community Resources • Modding API Updates • Programming Languages • List of server commands • List of client commands • Client startup parameters • Server startup parameters Example Mods • API Docs • GitHub Repository |