03.03.2017, 02:56
Код:
CMD:admins(playerid, params[]) { new string[256]; new Rank[256]; new AFK[256]; // --> AFK SendClientMessage(playerid, -1, "** Administrators **"); for(new i=0; i<MAX_PLAYERS; i++) { if(IsPlayerConnected(i)) { if(pInfo[i][pAdmin] > 0) { switch(pInfo[i][pAdmin]) { case 1: Rank = "Moderator"; case 2: Rank = "Master Moderator"; case 3: Rank = "Admin"; case 4: Rank = "Master Admin"; case 5: Rank = "Developer"; case 6: Rank = "Web Developer"; case 7: Rank = "Owner"; } new spName[MAX_PLAYER_NAME]; GetPlayerName(i,spName,MAX_PLAYER_NAME); if(AFK[playerid]>0) // --> AFK ? { format(string,sizeof(string),"%s %s [Id:%d] %s {008080}[AFK]",Rank,spName,i,pInfo[i][pAdmin],AFK); // --> AFK ? } else { format(string,sizeof(string),"%s %s [Id:%d] %s",Rank,spName,i,pInfo[i][pAdmin]); // --> Back ? SendClientMessage(playerid, -1, string); } } } }