27.06.2016, 04:59
PHP код:
CMD:admins(playerid)
{
if(PlayerInfo[playerid][pVip] >= 1 || PlayerInfo[playerid][Level] >= 1)
{
Str[0] = '\0';
new TotalCount,HonnCaption[52],Status[64],HonnT[24],FullString[600];
foreach(new i: Player)
{
if(PlayerInfo[i][Level] >= 1)
{
if(IsPlayerAdmin(i)) HonnT = "{00FF00}Yes";
else if(!IsPlayerAdmin(i)) HonnT = "{FF0000}No";
//------------------------------------------------------------------
if(PlayerInfo[i][AFKBRB] == 1) Status = "{FFFF00}AFK";
else if(PlayerInfo[i][Hidden] == 1) Status = "{FF8000}Hidden";
else Status = "{FFFFFF}Playing";
//------------------------------------------------------------------
format(Str,sizeof(Str),"{00FF00}%s{FFFFFF}(%d)\t{00BBF6}%d\t%s\t%s\n%s",PlayerName(i),i,PlayerInfo[i][Level],Status,HonnT,Str);
TotalCount ++;
}
}
format(HonnCaption, 128, "{00BBF6}Online Admins - {FF0000}%d", TotalCount);
format(FullString,sizeof(FullString),"Admin Name\tLevel\tStatus\tRCON Acces\n%s",Str);
if(TotalCount == 0)return GameTextForPlayer(playerid, "~w~~h~No Admins ~r~~h~Online", 3000, 4);
else return ShowPlayerDialog(playerid, 123, DIALOG_STYLE_TABLIST_HEADERS, HonnCaption, FullString, "Close", "");
}
else return SendLangInfo(playerid, "{FF0000}Vrei sa raportezi un jucator? Foloseste /Report [ID] [Motiv] !", "Do you wanna report someone? Use /Report [ID] [Reason] !");
}