21#include <entt/entt.hpp>
64static_assert(std::is_trivially_copyable_v<RagdollBoneTag>,
65 "RagdollBoneTag must be trivially copyable for network serialization");
74 std::array<entt::entity, 14u>
joints{};
Network client identifier component for multiplayer entities.
constexpr bool kRagdollsEnabled
Master switch for the ragdoll feature (creation, physics, rendering).
Definition Ragdoll.hpp:31
RagdollBone
Standard humanoid bone indices for the 15-body ragdoll.
Definition Ragdoll.hpp:36
@ FootL
Definition Ragdoll.hpp:50
@ UpperLegR
Definition Ragdoll.hpp:47
@ LowerLegL
Definition Ragdoll.hpp:48
@ HandR
Definition Ragdoll.hpp:45
@ LowerLegR
Definition Ragdoll.hpp:49
@ Torso
Definition Ragdoll.hpp:38
@ Head
Definition Ragdoll.hpp:37
@ ForearmR
Definition Ragdoll.hpp:43
@ FootR
Definition Ragdoll.hpp:51
@ UpperArmR
Definition Ragdoll.hpp:41
@ UpperArmL
Definition Ragdoll.hpp:40
@ ForearmL
Definition Ragdoll.hpp:42
@ UpperLegL
Definition Ragdoll.hpp:46
@ Pelvis
Definition Ragdoll.hpp:39
@ Count
Definition Ragdoll.hpp:52
@ HandL
Definition Ragdoll.hpp:44
Associates an entity with a connected network client.
Definition ClientId.hpp:10
Marker on each ragdoll-body entity; points back to the parent ragdoll character and which bone slot t...
Definition Ragdoll.hpp:58
ClientId characterId
Definition Ragdoll.hpp:60
entt::entity character
Definition Ragdoll.hpp:59
RagdollBone bone
Definition Ragdoll.hpp:61
Parent component on the dead character; holds the 15 ragdoll body entities and the joint entities con...
Definition Ragdoll.hpp:72
float age
Seconds since ragdoll spawn.
Definition Ragdoll.hpp:78
std::array< entt::entity, 14u > joints
14 joints for 15 bones in tree topology.
Definition Ragdoll.hpp:74
std::array< entt::entity, static_cast< size_t >(RagdollBone::Count)> bodies
Definition Ragdoll.hpp:73