Default team new account
#1

Hi all there. I made a gang wars server, with two teams. team 0 and team 1.
When I login to the server with a new account, I automatically sets the team 0, when in fact it should have no team. How could I do to set the team's 255 (no team) if the player is new?
Reply
#2

Are we meant to guess your code?
Reply
#3

ok ok. edit:
pawn Код:
public OnPlayerConnect(playerid)
{
    if(fexist(UserPath(playerid)))
    {
        INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
        ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,"Login","Type your password below to login.","Login","Quit");
    }
    else
    {
        ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,"Registering...","Type your password below to register a new account.","Register","Quit");
    }
    GangZoneShowForAll(Zone1,COLOR_RED);
    GangZoneShowForAll(Zone2,0x000050);
    TextDrawShowForPlayer(playerid, SVname);
  if(PlayerInfo[playerid] [pTeam] == 255)
  {
  ShowPlayerDialog(playerid, DIALOG_GANGCHANGE, DIALOG_STYLE_LIST, "Selecteaza-ti noul gang","{FF0000}Red Dragon Triad\n{808080}The Corleone Family", "Schimba", "Anuleaza");
  }
  SetPlayerTeam(playerid, 255);
 
 
 
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)