Small problem with /admins
#1

Hey, i seem to have a problem with /admins, it shows all the admins as a moderator, even level 3 admins.
Код:
	if (strcmp(cmd, "/admins", true) == 0)
	{
    if(IsPlayerConnected(playerid))
	  {
	    SendClientMessage(playerid, COLOR_LIGHTBLUE, "|____ Online IBP Admins ____|");
			for(new i = 0; i < MAX_PLAYERS; i++)
			{
				if(IsPlayerConnected(i))
				{
				  if(PlayerInfo[i][pAdmin] >= 1 && PlayerInfo[i][pAdmin] < 1338)
				  {
				    new admtext[64];
						if (PlayerInfo[playerid][pAdmin] >= 1) { admtext = "Moderator"; }
						else if (PlayerInfo[playerid][pAdmin] >= 2) { admtext = "Admin"; }
					  else if (PlayerInfo[playerid][pAdmin] >= 3) { admtext = "Lead Admin"; }
						else { admtext = "Moderator"; }
						GetPlayerName(i, sendername, sizeof(sendername));
						if(AdminDuty[i] == 0)
						{
							format(string, 256, "%s: %s", admtext, sendername);
							SendClientMessage(playerid, COLOR_WHITE, string);
						}
						else
						{
						  format(string, 256, "%s: %s (on duty)", admtext, sendername);
							SendClientMessage(playerid, COLOR_WHITE, string);
						}
					}
				}
			}
		}
		return 1;
	}
Anybody who has a idea whats wrong here?

THANKS !
Reply


Messages In This Thread
Small problem with /admins - by Guso - 29.12.2009, 22:24
Re: Small problem with /admins - by ben1 - 29.12.2009, 22:28
Re: Small problem with /admins - by KnooL - 29.12.2009, 22:37

Forum Jump:


Users browsing this thread: 1 Guest(s)