#include <RigidBody.hpp>
◆ CreateDynamic()
| RigidBody Physics::Component::RigidBody::CreateDynamic |
( |
float | bodyMass = 1.0f | ) |
|
|
inlinestatic |
Create a dynamic rigid body.
- Parameters
-
| bodyMass | Mass of the body in kg (default: 1.0) |
◆ CreateKinematic()
| RigidBody Physics::Component::RigidBody::CreateKinematic |
( |
| ) |
|
|
inlinestatic |
Create a kinematic rigid body.
◆ CreateStatic()
| RigidBody Physics::Component::RigidBody::CreateStatic |
( |
| ) |
|
|
inlinestatic |
Create a static rigid body.
◆ activation
| Activation Physics::Component::RigidBody::activation = Activation::Activate |
◆ allowSleeping
| bool Physics::Component::RigidBody::allowSleeping = true |
Allow body to go to sleep when inactive.
◆ angularDamping
| float Physics::Component::RigidBody::angularDamping = 0.05f |
Angular damping (resistance to rotation).
◆ friction
| float Physics::Component::RigidBody::friction = 0.5f |
Friction coefficient [0, 1].
◆ gravityFactor
| float Physics::Component::RigidBody::gravityFactor = 1.0f |
Gravity factor (1.0 = normal gravity, 0.0 = no gravity).
◆ linearDamping
| float Physics::Component::RigidBody::linearDamping = 0.05f |
Linear damping (resistance to linear motion).
◆ mass
| float Physics::Component::RigidBody::mass = 1.0f |
Mass in kg (only for Dynamic bodies).
◆ motionType
| MotionType Physics::Component::RigidBody::motionType = MotionType::Dynamic |
Motion type (Static, Kinematic, or Dynamic).
◆ objectLayer
| uint16_t Physics::Component::RigidBody::objectLayer = 0 |
Object layer for collision filtering (0 = NON_MOVING, 1 = MOVING) Use CreateDynamic/CreateStatic/CreateKinematic helpers for correct defaults
◆ restitution
| float Physics::Component::RigidBody::restitution = 0.0f |
Restitution/bounciness [0, 1].
The documentation for this struct was generated from the following file: