Spawn help - 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: Spawn help (
/showthread.php?tid=601441)
Spawn help -
RedRex - 21.02.2016
Hello Why i cant spawn

and i cant select class/skin

Can some one help me plesae?
Re: Spawn help -
ReshiramZekrom - 21.02.2016
Stop copying scripts and you'll don't have these kind of errors.. Check what is going on with OnPlayerConnect and with OnPlayerRequestClass
Re: Spawn help -
RedRex - 21.02.2016
Look Here is OnPlayerRequestClass
Код:
public OnPlayerRequestClass(playerid,classid)
{
if(classid == 3 && !IsPlayerAdmin(playerid))
{
SendClientMessage(playerid, COLOR_RED, "This skin is only for admins!");
return 0;
}
return 1;
}
aand here for onplayerconnect
Код:
public OnPlayerConnect(playerid)
{
new string[64], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid,pName,MAX_PLAYER_NAME);
format(string,sizeof string,"%s has joined the server. Welcome!",pName);
SendClientMessageToAll(0xFFFFFFAA,string);
return 1;
}
There is no errors right?
Re: Spawn help -
Joron - 21.02.2016
Hey how u get your your black box with "spawn" to look like that?
Re: Spawn help -
RedRex - 21.02.2016
ops Wrong lool

wait let me post OnPlayerSpawn xD
Код:
public OnPlayerSpawn(playerid)
{
new PlayerName[MAX_PLAYER_NAME],
string[40];
GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
format(string, sizeof(string), "%s has spawned successfully.", PlayerName);
SendClientMessageToAll(0xFFFFFFFF, string);
return 1;
}