Problem with Y_Ini
#6

It's probably because you're calling it under OnPlayerRequestSpawn, and when the player first connects it gets called before the players data is loaded, there fore it doesn't know what the value of RulesRead is. Try doing it on OnPlayerSpawn, something like this:

pawn Код:
public OnPlayerSpawn(playerid)
{
    if(gIsPlayerLoggedIn)
    {
        // spawn codes
    }
    else
    {
        if(pInfo[playerid][RulesRead] == 0)
        {
            // show rules
        }
        else
        {
            // show login/register..
        }
    }
    return 1;
}
Reply


Messages In This Thread
Problem with Y_Ini - by iOxide - 25.06.2014, 11:14
Re: Problem with Y_Ini - by Jack_Leslie - 25.06.2014, 11:16
Re: Problem with Y_Ini - by iOxide - 25.06.2014, 11:21
Re: Problem with Y_Ini - by Jack_Leslie - 25.06.2014, 11:22
Re: Problem with Y_Ini - by iOxide - 25.06.2014, 11:25
Re: Problem with Y_Ini - by Jack_Leslie - 25.06.2014, 11:30
Re: Problem with Y_Ini - by Threshold - 25.06.2014, 11:38
Re: Problem with Y_Ini - by Jack_Leslie - 25.06.2014, 12:30
Re: Problem with Y_Ini - by Threshold - 25.06.2014, 13:01
Re: Problem with Y_Ini - by Jack_Leslie - 25.06.2014, 13:03

Forum Jump:


Users browsing this thread: 1 Guest(s)