Problem with online administrators.
#4

Try this:
pawn Код:
if (strcmp(cmd, "/admins", true) == 0)
{
        if(IsPlayerConnected(playerid))
        {
            SendClientMessage(playerid, COLOR_GREY, "Admins Online:");
            for(new i = 0; i < PLAYERS; i++)
            {
                if(IsPlayerConnected(i))
                {
                        if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] <= 5000)
                        {
                            new admtext[64];
                            if(PlayerInfo[i][pAdmin] == 5000) { format(admtext,sizeof(admtext),"Server Developer"); }
                            else if(PlayerInfo[i][pAdmin] == 1338) { format(admtext,sizeof(admtext),"Head Administrator"); }
                            else if(PlayerInfo[i][pAdmin] == 3) { format(admtext,sizeof(admtext),"Administrator Level 3"); }
                            else if(PlayerInfo[i][pAdmin] == 2)    { format(admtext,sizeof(admtext),"Administrator Level 2"); }
                            else if(PlayerInfo[i][pAdmin] == 1) { format(admtext,sizeof(admtext),"Administrator Level 1"); }
                            else { format(admtext,sizeof(admtext),"Lead Administrator"); }
                            GetPlayerName(i, sendername, sizeof(sendername));

                            if(AdminDuty[i] == 0)
                            {
                                format(string, sizeof(string), "(%s) %s (ID: %d) Adminduty: No",admtext, GetPlayerNameEx(i), i);
                                SendClientMessage(playerid, COLOR_GREY, string);
                            }
                            else
                            {
                                format(string, sizeof(string), "(%s) %s (ID: %d) Adminduty: Yes",admtext, GetPlayerNameEx(i), i);
                                SendClientMessage(playerid, COLOR_GROVE, string);
                            }


                  }
            }

        }
        return 1;
}
Reply


Messages In This Thread
Problem with online administrators. - by DemME - 24.05.2014, 16:09
Re : Problem with online administrators. - by S4t3K - 24.05.2014, 16:13
Re: Problem with online administrators. - by Barnwell - 24.05.2014, 16:14
Re: Problem with online administrators. - by iFiras - 24.05.2014, 16:14
Re: Problem with online administrators. - by Jefff - 24.05.2014, 16:15
Re: Problem with online administrators. - by Jacksta21 - 24.05.2014, 16:16
Re: Problem with online administrators. - by DemME - 24.05.2014, 16:46

Forum Jump:


Users browsing this thread: 1 Guest(s)