PhysicsEntityBase
Inherits from SpatialEntity
Summary
Constructors
PhysicsEntityBase(other: EntityBusPeer) |
PhysicsEntityBase(other: Entity) |
PhysicsEntityBase(other: SpatialEntity) |
Properties
Name | Type |
---|---|
mass | float |
invMass | float |
linearVelocity | Vec3 | nil |
angularVelocity | Vec3 | nil |
position | Vec3 | nil |
sleeping | bool |
addedToWorld | bool |
partCount | int |
gravityFactor | float |
friction | float |
restitution | float |
linearDamping | float |
angularDamping | float |
userData | Entity | nil |
Methods
Method | Returns |
---|---|
AddToWorld() | void |
RemoveFromWorld() | void |
GetPart(partId: int) | Entity | Component | nil |
GetPartTransform(partId: int) | QuatTransform | nil |
GetPartMaterial(partId: int) | DataContainer | nil |
GetPartMaterial(partId: int, atPos: Vec3) | DataContainer | nil |
GetPartMaterialFlags(partId: int) | int |
GetProperty(propertyId: int) | int |
SetProperty(propertyId: int, value: int) | void |
RemoveProperty(propertyId: int) | int |
SetMass(mass: float, updateInertia: bool) | void |
ApplyForce(deltaTime: float, force: Vec3) | void |
ApplyForce(deltaTime: float, force: Vec3, position: Vec3) | void |
ApplyTorque(deltaTime: float, torque: Vec3) | void |
Static members
Name | Type |
---|---|
PhysicsEntityBase.typeInfo | TypeInformation |
Constructors
PhysicsEntityBase
PhysicsEntityBase(other: EntityBusPeer)
Parameters
Name | Type | Description |
---|---|---|
other | EntityBusPeer |
PhysicsEntityBase
PhysicsEntityBase(other: Entity)
Parameters
Name | Type | Description |
---|---|---|
other | Entity |
PhysicsEntityBase
PhysicsEntityBase(other: SpatialEntity)
Parameters
Name | Type | Description |
---|---|---|
other | SpatialEntity |
Properties
mass
float
invMass
float
linearVelocity
Vec3 | nil
angularVelocity
Vec3 | nil
position
Vec3 | nil
sleeping
bool
addedToWorld
bool
partCount
int
gravityFactor
float
friction
float
restitution
float
linearDamping
float
angularDamping
float
userData
Entity | nil
Methods
AddToWorld
AddToWorld()
RemoveFromWorld
RemoveFromWorld()
GetPart
Parameters
Name | Type | Description |
---|---|---|
partId | int |
Returns
Type | Description |
---|---|
Entity | Component | nil |
GetPartTransform
GetPartTransform(partId: int): QuatTransform | nil
Parameters
Name | Type | Description |
---|---|---|
partId | int |
Returns
Type | Description |
---|---|
QuatTransform | nil |
GetPartMaterial
GetPartMaterial(partId: int): DataContainer | nil
Parameters
Name | Type | Description |
---|---|---|
partId | int |
Returns
Type | Description |
---|---|
DataContainer | nil |
GetPartMaterial
GetPartMaterial(partId: int, atPos: Vec3): DataContainer | nil
Parameters
Name | Type | Description |
---|---|---|
partId | int | |
atPos | Vec3 |
Returns
Type | Description |
---|---|
DataContainer | nil |
GetPartMaterialFlags
GetPartMaterialFlags(partId: int): int
Parameters
Name | Type | Description |
---|---|---|
partId | int |
Returns
Type | Description |
---|---|
int |
GetProperty
GetProperty(propertyId: int): int
Parameters
Name | Type | Description |
---|---|---|
propertyId | int |
Returns
Type | Description |
---|---|
int |
SetProperty
SetProperty(propertyId: int, value: int)
Parameters
Name | Type | Description |
---|---|---|
propertyId | int | |
value | int |
RemoveProperty
RemoveProperty(propertyId: int): int
Parameters
Name | Type | Description |
---|---|---|
propertyId | int |
Returns
Type | Description |
---|---|
int |
SetMass
SetMass(mass: float, updateInertia: bool)
Parameters
Name | Type | Description |
---|---|---|
mass | float | |
updateInertia | bool |
ApplyForce
ApplyForce(deltaTime: float, force: Vec3)
Parameters
Name | Type | Description |
---|---|---|
deltaTime | float | |
force | Vec3 |
ApplyForce
Parameters
Name | Type | Description |
---|---|---|
deltaTime | float | |
force | Vec3 | |
position | Vec3 |
ApplyTorque
ApplyTorque(deltaTime: float, torque: Vec3)
Parameters
Name | Type | Description |
---|---|---|
deltaTime | float | |
torque | Vec3 |
Static members
typeInfo
Last modified May 2, 2022: Add changelog for build 18616 (95be163f)