Prop ragdoll
Template:Point ent It is a VPhysics ragdoll. Ragdolls are collections of physics objects constrained together to simulate a jointed object like a dead body. They are very expensive to simulate.






physics_prop_ragdoll
. See also Prop Types Overview.
Death Ragdolls/Ragdoll Transformation
When a NPC/player dies or an entity receives the BecomeRagdoll
input, it normally creates a client-side ragdoll and copies most of its animation and visual data to it. Unlike server-side prop_ragdolls, these client-side ragdolls are handled completely on a per-client basis and are much cheaper and simpler than their server-side counterparts, at the expense of being virtually nonexistent on the server, being inconsistent across client perspectives, and only colliding with entities that have physics objects on the client (e.g. worldspawn).
However, a NPC will become a server-side ragdoll while it's under any of the following conditions:
- The NPC is inside the volume of a trigger_serverragdoll
- The NPC is killed by a vehicle in singleplayer
- The gravity gun is supercharged
- The NPC dies on fire while in Alyx darkness mode
- The NPC is a vital ally (e.g., npc_alyx)
These server-side death ragdolls will collide with physics objects and beyond, like any prop_ragdoll, but they are marked as debris and do not collide with each other. They do not collide with themselves either, unlike client-side ragdolls. This is believed to be intentional behavior to reduce performance/networking costs.


Code:This can be modified at
CBaseAnimating::CopyAnimationDataFrom()
inbaseanimating.cpp
for server-side ragdolls andC_BaseAnimating::CreateRagdollCopy()
inc_baseanimating.cpp
for client-side ragdolls.
Keyvalues
- sequence ([todo internal name (i)]) <integer> !FGD
- The ragdoll will be moved to the first frame of this animation before VPhysics takes over.
Bug:Doesn't function. [todo tested in ?]
- Body (body) <integer> !FGD
- Specifies which body group should be used.
- Override Animation (angleOverride) <string>
- Filled in by the engine via wc_update_entity. Do not edit by hand except to clear.
GMODSandbox:
- Allow Physics Gun (gmod_allowphysgun) <boolean> (only in
)
- If set, players cannot use Physics Gun on this entity.
- Sandbox Tool Whitelist (gmod_allowtools) <string> (only in
)
- If set, only given tools can be used on this entity. You need to supply the tool class names, the names of the
.lua
files of those tools. This also includes the context menu properties!

Flags
- Debris : [4]
- Don't collide with the player or other debris
- Allow Dissolve : [8192]
- Motion Disabled : [16384]
- Allow stretch : [32768]
- Start asleep : [65536]
Inputs
- StartRagdollBoogie
- Begins ragdoll boogie effect for 5 seconds.
Bug:This input is actually supposed to use a parameter for how long the ragdoll should boogie, but it uses the wrong field type in the data description. [todo tested in ?]
Code Fix:In
CRagdollProp
's data description, findDEFINE_INPUTFUNC( FIELD_VOID, "StartRagdollBoogie", InputStartRadgollBoogie )
and replaceFIELD_VOID
withFIELD_FLOAT
.
- EnableMotion, DisableMotion
- Enable/disable physics simulation.
- FadeAndRemove (in all games since
)
- Fade out then remove (kill) self. Parameter override = duration of fade.

Outputs
