Table of Contents

Class EntityBehaviorPassivePhysics

Namespace
Vintagestory.API.Common
Assembly
VintagestoryAPI.dll

Passive physics system for entities.
Uses the "passivephysics" code Open in GitHub

[DocumentAsJson]
[AddDocumentationProperty("waterDragFactor", "Gravity drag factor when in water", "System.Double", "Optional", "1", false)]
[AddDocumentationProperty("airDragFactor", "Gravity drag factor when falling. Overrides airDragFallingFactor when present", "System.Double", "Optional", "1", false)]
[AddDocumentationProperty("airDragFallingFactor", "Gravity drag factor when falling", "System.Double", "Optional", "1", false)]
[AddDocumentationProperty("groundDragFactor", "Horizontal drag factor when on the ground", "System.Double", "Optional", "1", false)]
[AddDocumentationProperty("gravityFactor", "Multiplier for gravity strength", "System.Double", "Optional", "1", false)]
public class EntityBehaviorPassivePhysics : PhysicsBehaviorBase
Inheritance
EntityBehaviorPassivePhysics
Derived

Examples

"behaviors": [
 {
    "code": "passivephysics"
    "groundDragFactor": 1,
    "airDragFactor": 0.25,
    "gravityFactor": 0.75
 }
]

Fields

airDragFactor (Optional) (Default: 1)

Gravity drag factor when falling. Overrides airDragFallingFactor when present

Field Value

Double

airDragFallingFactor (Optional) (Default: 1)

Gravity drag factor when falling

Field Value

Double

gravityFactor (Optional) (Default: 1)

Multiplier for gravity strength

Field Value

Double

groundDragFactor (Optional) (Default: 1)

Horizontal drag factor when on the ground

Field Value

Double

waterDragFactor (Optional) (Default: 1)

Gravity drag factor when in water

Field Value

Double