Player "dies" but do not respawn.
#1

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?
Reply
#2

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.
Reply
#3

Ok , Ill try the SpawnPlayer.
But its not fixable?
Reply
#4

It is fixable, but I don't know what the problem is with your death system, your OnPlayerDeath might be bugged.
Reply
#5

Post your code under OnPlayerDeath
Reply
#6

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 FloatX, FloatY, FloatZ;
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;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)