SA-MP Forums Archive
Player Spawns not working - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Player Spawns not working (/showthread.php?tid=223200)



Player Spawns not working - darkknight123 - 09.02.2011

this is my "OnPlayerRequestClass" Code but some times idk when players accounts will go all crazy and it will say "You are not logged in" I dont know whats wrong it started when i tryed to skip the class selection with a 5 millisecond timer
Код:
public OnPlayerRequestClass(playerid, classid)
{
    SetTimerEx("SkipSpawn",5,0,"i",playerid);
    if(IsPlayerNPC(playerid))
	{
	    printf("NPC: OnPlayerRequestClass: %d", playerid);
	    return 1;
	}
    if(gPlayerLogged[playerid] == 0)
    {
		TogglePlayerSpectating(playerid, 1);
		return 1;
	}
	SetupPlayerForClassSelection(playerid);
	if(gPlayerSpawned[playerid] == 1)
	{
	    if(PlayerInfo[playerid][pMember] > 0 || PlayerInfo[playerid][pLeader] > 0 || PlayerInfo[playerid][pFMember] != 255)
		{
		    SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]);
		}
		else
		{
			PlayerInfo[playerid][pModel] = PedSkins[classid][0];
		}
	}
	else
	{
	    SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]);
	}

	return 1;
}



Re: Player Spawns not working - (SF)Noobanatior - 09.02.2011

can i see the skipspawn function


Re: Player Spawns not working - darkknight123 - 09.02.2011

here
Quote:

public SkipSpawn(playerid)
{
SpawnPlayer(playerid);
return 1;
}




Re : Player Spawns not working - Amine_Mejrhirrou - 09.02.2011

this is the public OnPlayerRequestClass(playerid, classid)

show us your
public OnPlayerSpawn(playerid)


Re: Player Spawns not working - darkknight123 - 09.02.2011

here i took everything out from it because it was all buged before this but here

Код:
public OnPlayerSpawn(playerid)
{
return 1;
}



Re: Player Spawns not working - darkknight123 - 10.02.2011

bump