SA-MP Forums Archive
Death Bug - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Death Bug (/showthread.php?tid=654489)



Death Bug - TheBeastKhan - 29.05.2018

I added a new FS to my server. HeadShot FS It is working way too fine but when we kill a person he dies, but doesn't respawn and still able to chat, rob and walk. Not only by HS but if we use /kill, we are still not respawning, and person is moving with 0 health :/

EDIT:- The player doesn't respawn until an admin uses /spawn command!


Re: Death Bug - Exhibit - 30.05.2018

Post the code from the filterscript and the gamemode. OnPlayerDeath and OnPlayerTakeDamage.


Re: Death Bug - GTLS - 30.05.2018

Use SpawnPlayer under OnPlayerDeath


Re: Death Bug - TheBeastKhan - 30.05.2018

I dont have OnplayerDeath! on mah fs! Should i add that!


Re: Death Bug - GTLS - 30.05.2018

Yes.

https://sampwiki.blast.hk/wiki/OnPlayerDeath

That is called when a player dies. Put your code of after death here. If nothing is written here, obviously, nothing will happen.


Re: Death Bug - TheBeastKhan - 30.05.2018

You mean put the code of afterdeath on Gm in Fs??


Re: Death Bug - PawnFox - 30.05.2018

no, just put

Код:
public OnPlayerDeath ( playerid, killerid, reason )
{
    return 1;
}
You will be spawned automatically, not needed to add SpawnPlayer(playerid) tho.


Re: Death Bug - TheBeastKhan - 01.06.2018

Still player doesn't spawns sometimes after being killed! We have to use /spawn command:/


Re: Death Bug - GTLS - 01.06.2018

Did you tried adding SpawnPlayer inside OnPlayerDeath as I said above?


Re: Death Bug - Exhibit - 04.06.2018

Quote:
Originally Posted by Exhibit
Посмотреть сообщение
Post the code from the filterscript and the gamemode. OnPlayerDeath and OnPlayerTakeDamage.
Nobody can help you unless you post the code.