Player "dies" but do not respawn. -
Lincoln.C - 09.11.2011
Hello. I have this bad problem. When a Player dies because of SetPlayerHealth to 0 or by getting shot by an other player, he has no more HP but he can run. I have the same problem now! I can shot, i can run. But i wouldnt Die. I thried the /adminkill [myname] that sets my HP to 0 and its the same, no really death and no respawn.
Someone help please?
Re: Player "dies" but do not respawn. -
grand.Theft.Otto - 09.11.2011
When they die (OnPlayerDeath) put SpawnPlayer(playerid); under it. This will spawn the player when he dies.
Only problem is the swinging death camera gets skipped.
AW: Player "dies" but do not respawn. -
Lincoln.C - 09.11.2011
Ok , Ill try the SpawnPlayer.
But its not fixable?
Re: Player "dies" but do not respawn. -
grand.Theft.Otto - 09.11.2011
It is fixable, but I don't know what the problem is with your death system, your OnPlayerDeath might be bugged.
Re: Player "dies" but do not respawn. -
[MG]Dimi - 09.11.2011
Post your code under OnPlayerDeath
AW: Player "dies" but do not respawn. -
Lincoln.C - 11.11.2011
Its just the Gangfight function, Reset some Values and Weapons
I still dont know the reason for this bug.
Everything works fine, no Errors or warnings at the compiler.
Thanks for tanking time
public OnPlayerDeath(playerid, killerid, reason)
{
new Float
![Tongue](images/smilies/razz.gif)
X, Float
![Tongue](images/smilies/razz.gif)
Y, Float
![Tongue](images/smilies/razz.gif)
Z;
ResetPlayerGuns(playerid);
GetPlayerPos(playerid, pX, pY, pZ);
DrugAmount[playerid] = 0;
KillTimer(DrugTimer[playerid]);
p[playerid][Deaths]++;
if(killerid != INVALID_PLAYER_ID) { p[killerid][Kills]++; }
CopDuty[playerid] = 0;
return 1;
}