Server closes connection after tutorial? - 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: Server closes connection after tutorial? (
/showthread.php?tid=327087)
Server closes connection after tutorial? -
cloudysky - 19.03.2012
Hey, recently made a tutorial but at the end of it, it kicks the player. Can anyone help me?
pawn Код:
stock Tutorial(playerid)
{
TogglePlayerSpectating(playerid, 1);
TextDrawShowForPlayer(playerid, Text:Textdraw0);
TextDrawShowForPlayer(playerid, Text:Textdraw1);
TextDrawShowForPlayer(playerid, Text:Textdraw2);
TextDrawShowForPlayer(playerid, Text:Textdraw3);
SetTimer("tutorialtimer", 10000, false);
return 1;
}
pawn Код:
public tutorialtimer(playerid)
{
TogglePlayerSpectating(playerid, 0);
TextDrawHideForPlayer(playerid, Text:Textdraw0);
TextDrawHideForPlayer(playerid, Text:Textdraw1);
TextDrawHideForPlayer(playerid, Text:Textdraw2);
TextDrawHideForPlayer(playerid, Text:Textdraw3);
SetPlayerPos(playerid, -2281.6372, 2288.2834, 4.9698);
return 1;
}
Re: Server closes connection after tutorial? -
new121 - 19.03.2012
Do you have "SpawnPlayer" anywhere in your tutorial? if you do make sure you use the SetSpawnInfo function before hand
Re: Server closes connection after tutorial? -
cloudysky - 19.03.2012
EDIT: Fixed it, I figured out that it was clashing with 'OnPlayerRequestClass.'