TBoxComponent
Hierarchy
- default
- TBoxComponent
Index
Constructors
Properties
Accessors
Methods
Constructors
constructor
Properties
publicactor
publiccanRender
Indicates whether a component has the ability to be rendered.
publicoptionalcollider
Collider for this component.
publicdead
publicdepth
publicheight
publicoptionalmaterial
publicoptionalparentComponent
Parent of this component. If undefined, it is a root component.
publicshouldRender
Indicates whether a component should be rendered
publictransform
Transform relative to the parent or actor (if has no parent).
publicuuid
publicwidth
Accessors
publicangularVelocity
Returns undefined | vec3
publicbodyOptions
Get physics body config for scene component
Returns TPhysicsBodyOptions
publiclinearVelocity
Returns undefined | vec3
Methods
publicapplyCentralForce
Parameters
force: vec3
Returns void
publicapplyCentralImpulse
Parameters
impulse: vec3
Returns void
publicapplyMaterial
Parameters
engine: default
path: string
Returns Promise<void>
publicapplyMesh
Clears the current mesh and starts loading the new mesh
Parameters
engine: default
path: string
Returns Promise<void>
publicapplyTransform
Apply transforms ensure transform updates get propagated to the physics world
Returns void
publicattachTo
Attaches the component as a child to the given component.
Parameters
parentComponent: default
Returns void
publicdestroy
Returns void
publicgetRenderTask
Returns undefined | TSerializedMeshInstance
publicgetWorldTransform
Gets the component to world transform
Returns default
publicsetAngularDamping
Parameters
damping: number
Returns void
publicsetAngularVelocity
Parameters
velocity: vec3
Returns void
publicsetBodyType
Parameters
type: TPhysicsBodyType
Returns void
publicsetColor
Parameters
color: TColor
Returns void
publicsetColors
Parameters
palette: { back: TColor; bottom: TColor; front: TColor; left: TColor; right: TColor; top: TColor }
back: TColor
bottom: TColor
front: TColor
left: TColor
right: TColor
top: TColor
Returns void
publicsetFixedRotation
Parameters
fixedRotation: boolean
Returns void
publicsetFriction
Parameters
friction: number
Returns void
publicsetIsTrigger
Triggers don't collide with other objects, but they still trigger collision events
Parameters
isTrigger: boolean
Returns void
publicsetLinearDamping
Parameters
damping: number
Returns void
publicsetLinearVelocity
Parameters
velocity: vec3
Returns void
publicsetMaterial
Parameters
material: default
Returns void
publicsetMesh
Parameters
engine: default
positions: number[]
normals: number[]
indexes: number[]
colors: number[]
paletteIndex: TPaletteIndex
Returns Promise<void>
publicupdatePhysicsBody
Set physics body for this component, this is automatically called by the physics world. Changing this will not update the physics world, use the various
set
methods instead.Parameters
body: undefined | TPhysicsBody
Returns void
Component for an actor. Only contains updater and cannot be rendered.