Physics rigidbody component. Stores the physical parameters of an object. Such as moment of inertia, mass, velocity, angular momentum, air drag, force, torque, etc...
More...
#include <Components.hpp>
|
| RigidBody (float height, float width, float depth, float m) |
|
void | setMomentCube (float height, float width, float depth, float m) |
| Set the moment of inertia of this rigidbody to that of a solid cube. More...
|
|
|
glm::vec3 | velocity = glm::vec3(0, 0, 0) |
| velocity vector
|
|
glm::vec3 | force = glm::vec3(0, 0, 0) |
| force vector
|
|
float | airDrag = 0.1f |
| air drag co-efficient
|
|
float | angularDrag = 1.f |
| air drag co-efficient
|
|
bool | kinematic = true |
| is the object affected by physics
|
|
glm::mat3 | moment |
| moment of inertia
|
|
glm::mat3 | invMoment |
| inverse moment of inertia
|
|
glm::vec3 | w = glm::vec3(0, 0, 0) |
| Angular velocity.
|
|
glm::vec3 | t = glm::vec3(0, 0.f, 0) |
| Torque.
|
|
Ref< PhysicsEntity > | physicsEntity |
| Reference to an active physics entity.
|
|
float | iMass = 1 |
| inverse mass
|
|
float | drag = 2.98f |
| drag co-efficient
|
|
bool | grounded = true |
| grounded flag
|
|
Physics rigidbody component. Stores the physical parameters of an object. Such as moment of inertia, mass, velocity, angular momentum, air drag, force, torque, etc...
◆ setMomentCube()
void Engine::RigidBody::setMomentCube |
( |
float |
height, |
|
|
float |
width, |
|
|
float |
depth, |
|
|
float |
m |
|
) |
| |
|
inline |
Set the moment of inertia of this rigidbody to that of a solid cube.
- Parameters
-
The documentation for this struct was generated from the following file: