[Y_INI]Registering with another account loads previous playerid account
#7

Quote:
Originally Posted by xXmAn40100Xx
Посмотреть сообщение
Thanks, it works! +rep for everybody

Also, can it work with a Loop? I mean

pawn Код:
stock ResetPlayerVariables(playerid)
{
          for(new i=0 ; i < pInfo ; i++)
         {
               //code here
         }
          return 1;
}
pawn Код:
public ResetPlayerVariables(playerid)
{
    for(new E_PLAYERS:e; e < E_PLAYERS; ++e)
    {
        PlayerInfo[playerid][e] = 0;
    }
    return 1;
}
Just change E_PLAYERS to the name of your enum, and PlayerInfo to the name of your player variable, then pop ResetPlayerVariables(playerid); in OnPlayerConnect.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)