SA-MP Forums Archive
Problem Death player - 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: Problem Death player (/showthread.php?tid=644502)



Problem Death player - Kevin51 - 09.11.2017

Hello everyone.

I have a very small problem, when the player dies his returns him in the ClassSelection, but his only one time ..

Example: If I get killed a first time, it returns to ClassSelection, but the other times it works, I do not understand .. and it does it for everyone.

Have a idea ?


Re: Problem Death player - StrikerZ - 09.11.2017

PHP код:
public OnPlayerRequestClass(playerid,classid)
{
    
SpawnPlayer(playerid);
    return 
1;




Re: Problem Death player - Kevin51 - 09.11.2017

Quote:
Originally Posted by Sunehildeep
Посмотреть сообщение
PHP код:
public OnPlayerRequestClass(playerid,classid)
{
    
SpawnPlayer(playerid);
    return 
1;

I already tried, I tried a lot of things before thread.. no work

And then, it does not work because I have several teams, and we have no time to select are gang his spawn alone live with your proposal


Re: Problem Death player - StrikerZ - 09.11.2017

Quote:
Originally Posted by Kevin51
Посмотреть сообщение
I already tried, I tried a lot of things before thread.. no work
Search for ' ForceClassSelection(playerid); ' in your script
Edit: and do you want class selection at every death or not?


Re: Problem Death player - Kevin51 - 09.11.2017

Quote:
Originally Posted by Sunehildeep
Посмотреть сообщение
Search for ' ForceClassSelection(playerid); ' in your script
I just watched, everything is good, the ForceClassSelection is only in commands


Re: Problem Death player - StrikerZ - 09.11.2017

Quote:
Originally Posted by Kevin51
Посмотреть сообщение
I just watched, everything is good, the ForceClassSelection is only in commands
Can you check my edit in previous post? Need some more info


Re: Problem Death player - Kevin51 - 09.11.2017

No I want that when the player gets killed, respawn normally, and no sends to the classSelection


Re: Problem Death player - StrikerZ - 09.11.2017

Quote:
Originally Posted by Kevin51
Посмотреть сообщение
No I want that when the player gets killed, respawn normally, and no sends to the classSelection
Can you show your OnPlayerDeath and OnPlayerSpawn and OnPlayerRequestClass ?


Re: Problem Death player - Kevin51 - 09.11.2017

https://pastebin.com/VPRL07wg


Re: Problem Death player - StrikerZ - 09.11.2017

OK try this,
Print the value of classid and isConnected in OnPlayerRequestClass and show the logs after you die