In one of the plugins I'm working on, I'm trying to remove the dead body of a survivor after a certain criteria is met; However I've hit a dead end, there doesn't seem to be much info about removing bodies in Left 4 Dead.
I've tried teleporting them to an off the map area, I've tried using ragdoll removal code and the dissolver code; but none of them worked.
This is the ragdoll remove code I've been using. I don't think it works with L4D2.
PHP Code:
//Declare:
decl BodyRagdoll;
decl String:Classname[64];
//Initialize:
BodyRagdoll = GetEntPropEnt(client, Prop_Send, "m_hRagdoll");
if(IsValidEdict(BodyRagdoll))
{
//Find:
GetEdictClassname(BodyRagdoll, Classname, sizeof(Classname));
//Remove:
if(StrEqual(Classname, "cs_ragdoll", false)) RemoveEdict(BodyRagdoll);
}
__________________