Jump to content
major-stiffy

How to remove players dead body when he's dead

Recommended Posts

Request #1

I've searched and searched and found things close to want I wanted but what I found deletes all dead bodies/wrecks via a scripted timer like the one from Gunter Severloh. http://www.armaholic.com/page.php?id=23766 I only want to remove a players dead body and not dead AI. Player has the ability to respawn with gear he died with so I want his old body cleaned up.

 

 

Request #2

Similar to Ryd's mission Pilgrimage, if a player dies and respawns he has no clothes. He has to locate his dead body to recover his inventory. We prefer this method but I'll take either one.

 

Both will be while playing a COOP mission hosted by friends. (2-3 players).

 

 

Thanks

Share this post


Link to post
Share on other sites
9 minutes ago, major-stiffy said:

Request #1

I've searched and searched and found things close to want I wanted but what I found deletes all dead bodies/wrecks via a scripted timer like the one from Gunter Severloh. http://www.armaholic.com/page.php?id=23766 I only want to remove a players dead body and not dead AI. Player has the ability to respawn with gear he died with so I want his old body cleaned up.

 

 

Request #2

Similar to Ryd's mission Pilgrimage, if a player dies and respawns he has no clothes. He has to locate his dead body to recover his inventory. We prefer this method but I'll take either one.

 

Both will be while playing a COOP mission hosted by friends. (2-3 players).

 

 

Thanks

Solution 1:

 

//initPlayerLocal.sqf:

player addEventHandler ["Respawn",{ 

	params ["_newObject","_oldObject"];
	deleteVehicle _oldObject; 

}];

Will delete ye olde corpse upon respawn.

 

Solution 2:

 

//initPlayerLocal.sqf:

player addEventHandler ["Respawn",{

	player setUnitLoadout [[],[],[],[],[],[],"","",[],["ItemMap","","ItemRadio","ItemCompass","ItemWatch",""]];

}];

Upon respawn players will have no clothes. Well at least the most necessary ones.

 

Cheers

  • Like 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×