7#include <glm/gtc/quaternion.hpp>
9#include "core/reflect.h"
10#include "ecs/entity.h"
12namespace Vkm::Engine {
34 glm::quat lastRotation = {1.0f, 0.0f, 0.0f, 0.0f};
Names one entity of one Scene, for as long as that slot holds it.
Definition entity.h:23
One bone of a ragdoll, and the body that moves it.
Definition ragdoll.h:22
int32_t bone
Index into the rig's bone array.
Definition ragdoll.h:23
glm::mat4 bodyFromBone
Bone space -> body space: the bone as the body sees it.
Definition ragdoll.h:25
glm::vec3 lastPosition
Where the pose put the body last tick, world space; runtime, not serialized.
Definition ragdoll.h:33
EntityId body
The entity simulating it.
Definition ragdoll.h:24
Turns a rig over to physics, and back.
Definition ragdoll.h:49
std::vector< RagdollBone > bones
One per simulated bone.
Definition ragdoll.h:67
bool active
Physics drives the rig when true.
Definition ragdoll.h:50
float rigScale
The rig's world scale when the bones were built.
Definition ragdoll.h:66
int boneLayer
The layer bit the bones were built on.
Definition ragdoll.h:58
bool held
The pose held the bones last tick; runtime, not serialized.
Definition ragdoll.h:70
EntityId root
Node the bones are grouped under.
Definition ragdoll.h:51