SpawnPlayer only works when pressing arrows/spawn
#1

Hello,

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    if(GetPVarInt(playerid,"IsLogged") == 0)
    {
        new ip[16],string[128],Playername[MAX_PLAYER_NAME];
        GetPlayerIp(playerid,ip,sizeof(ip));
        GetPlayerRPName(playerid,Playername,sizeof(Playername));
        format(string,sizeof(string),"JOIN: {008000}%s (ID: %d). {008000}IP: %s. Country: %s",Playername,playerid,ip,GetPlayerCountryName(playerid));
        SendAdminMessage(COLOR_GREEN,string);
        format(string,sizeof(string),"INGAME JOIN: %s (ID: %d).",Playername,playerid);
        IRC_Say(IrcBot,"#GTAProductions",string);
    }
    SpawnPlayer(playerid);
    return 1;
}
With this code I got a weird problem. The player only spawns when I press one of the arrows, so that would mean OnPlayerRequestClass is not called when you go to the class request. What is the problem?

Note: OnPlayerRequestSpawn returns 1.

Jochem
Reply


Messages In This Thread
SpawnPlayer only works when pressing arrows/spawn - by Jochemd - 26.03.2011, 11:16
Re: SpawnPlayer only works when pressing arrows/spawn - by antonio112 - 26.03.2011, 11:29
Re: SpawnPlayer only works when pressing arrows/spawn - by Jochemd - 26.03.2011, 11:38

Forum Jump:


Users browsing this thread: 1 Guest(s)