Quantum 3 3.0.14

Public Member Functions | Public Attributes | List of all members
Quantum.Prototypes.PhysicsBody3DPrototype Class Reference

Prototype of the PhysicsBody3D Quantum component. More...

Inherits Quantum.ComponentPrototype< Quantum.PhysicsBody3D >.

Public Member Functions

sealed override bool AddToEntity (FrameBase f, EntityRef entity, in PrototypeMaterializationContext context)
 Creates an instance of the PhysicsBody3D component, materializes and adds it to the entity. More...
 
unsafe void Materialize (FrameBase frame, ref PhysicsBody3D component)
 
void Materialize (FrameBase frame, ref Quantum.PhysicsBody3D result, in PrototypeMaterializationContext context)
 Applies the prototype's fields to the actual component. More...
 

Public Attributes

FP AngularDrag = FP._0_50
 The PhysicsBody's angular drag. More...
 
FPVector3 CenterOfMass = FPVector3.Zero
 The PhysicsBody's center of mass. More...
 
QEnum8< Quantum.PhysicsBody3D.ConfigFlagsConfig = Quantum.PhysicsBody3D.ConfigFlags.Default
 The configuration flags used by the PhysicsBody. More...
 
FP Drag = FP._0_50
 The PhysicsBody's drag. More...
 
FPVector3 ExplicitInertiaTensor = FPVector3.One
 The body inertia tensor when InertiaMode is set to PhysicsBodyInertiaMode.Explicit. More...
 
NullableFP GravityScale = new NullableFP(){_hasValue = 0, _value = FP._1}
 The PhysicsBody's gravity scale. More...
 
PhysicsBodyInertiaMode InertiaMode = PhysicsBodyInertiaMode.ColliderShape
 The mode in which the body's inertia tensor is computed. More...
 
NullableFP InertiaScale = new NullableFP(){_hasValue = 0, _value = FP._1}
 The scale of the body inertia tensor. More...
 
FP Mass = 1
 The PhysicsBody's mass. More...
 
Shape3DConfig ParametricInertiaShape = new Shape3DConfig() { ShapeType = Shape3DType.Box, BoxExtents = FPVector3.One * FP._0_50 }
 The parametric shape used to compute the body inertia tensor when InertiaMode is set to PhysicsBodyInertiaMode.ParametricShape. More...
 
QEnum8< RotationFreezeFlagsRotationFreeze
 The PhysicsBody's rotation freeze flags. More...
 

Detailed Description

Prototype of the PhysicsBody3D Quantum component.

Member Function Documentation

◆ AddToEntity()

sealed override bool Quantum.Prototypes.PhysicsBody3DPrototype.AddToEntity ( FrameBase  f,
EntityRef  entity,
in PrototypeMaterializationContext  context 
)
inline

Creates an instance of the PhysicsBody3D component, materializes and adds it to the entity.

Parameters
f
entity
context
Returns
Returns true if adding the component to the entity succeeds.

◆ Materialize()

void Quantum.Prototypes.PhysicsBody3DPrototype.Materialize ( FrameBase  frame,
ref Quantum.PhysicsBody3D  result,
in PrototypeMaterializationContext  context 
)
inline

Applies the prototype's fields to the actual component.

Member Data Documentation

◆ Config

QEnum8<Quantum.PhysicsBody3D.ConfigFlags> Quantum.Prototypes.PhysicsBody3DPrototype.Config = Quantum.PhysicsBody3D.ConfigFlags.Default

The configuration flags used by the PhysicsBody.

◆ Mass

FP Quantum.Prototypes.PhysicsBody3DPrototype.Mass = 1

The PhysicsBody's mass.

◆ Drag

FP Quantum.Prototypes.PhysicsBody3DPrototype.Drag = FP._0_50

The PhysicsBody's drag.

◆ AngularDrag

FP Quantum.Prototypes.PhysicsBody3DPrototype.AngularDrag = FP._0_50

The PhysicsBody's angular drag.

◆ CenterOfMass

FPVector3 Quantum.Prototypes.PhysicsBody3DPrototype.CenterOfMass = FPVector3.Zero

The PhysicsBody's center of mass.

◆ RotationFreeze

QEnum8<RotationFreezeFlags> Quantum.Prototypes.PhysicsBody3DPrototype.RotationFreeze

The PhysicsBody's rotation freeze flags.

◆ GravityScale

NullableFP Quantum.Prototypes.PhysicsBody3DPrototype.GravityScale = new NullableFP(){_hasValue = 0, _value = FP._1}

The PhysicsBody's gravity scale.

◆ InertiaScale

NullableFP Quantum.Prototypes.PhysicsBody3DPrototype.InertiaScale = new NullableFP(){_hasValue = 0, _value = FP._1}

The scale of the body inertia tensor.

◆ InertiaMode

PhysicsBodyInertiaMode Quantum.Prototypes.PhysicsBody3DPrototype.InertiaMode = PhysicsBodyInertiaMode.ColliderShape

The mode in which the body's inertia tensor is computed.

◆ ExplicitInertiaTensor

FPVector3 Quantum.Prototypes.PhysicsBody3DPrototype.ExplicitInertiaTensor = FPVector3.One

The body inertia tensor when InertiaMode is set to PhysicsBodyInertiaMode.Explicit.

◆ ParametricInertiaShape

Shape3DConfig Quantum.Prototypes.PhysicsBody3DPrototype.ParametricInertiaShape = new Shape3DConfig() { ShapeType = Shape3DType.Box, BoxExtents = FPVector3.One * FP._0_50 }

The parametric shape used to compute the body inertia tensor when InertiaMode is set to PhysicsBodyInertiaMode.ParametricShape.