SA-MP Forums Archive
OnPlayerDeath - 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: OnPlayerDeath (/showthread.php?tid=577484)



OnPlayerDeath - JoshNudock - 11.06.2015

I have a problem when the player dies, the screen shows this:




I do not know how to fix, I studied all functions not found the solution ..


Re: OnPlayerDeath - AlexBlack - 11.06.2015

Show us the callback

public OnPlayerRequestClass(playerid, classid)


Re: OnPlayerDeath - Huba - 11.06.2015

Find it in onplayerdeath

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


Re: OnPlayerDeath - Konstantinos - 11.06.2015

It probably calls ForceClassSelection so on re-spawn, it shows the class selection.

Edit: Oh, you found it.

EDIT 2: Sorry, I thought the above user was the starter of the thread and got it fixed but my mistake.


Re: OnPlayerDeath - JoshNudock - 11.06.2015

Quote:
Originally Posted by Huba
Посмотреть сообщение
Quote:
Originally Posted by AlexBlack
Посмотреть сообщение
Show us the callback

public OnPlayerRequestClass(playerid, classid)
Has neither ..




Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
It probably calls ForceClassSelection so on re-spawn, it shows the class selection.

Edit: Oh, you found it.
How should I do? Do you have a base, please?


Re: OnPlayerDeath - FailerZ - 11.06.2015

try this
PHP код:
public OnPlayerRequestClass(playeridclassid)
{
    
SetSpawnInfo(playerid000000000000); //Edit those to match your script
    
SpawnPlayer(playerid);
    return 
1;




Re: OnPlayerDeath - JoshNudock - 11.06.2015

reputed!