04.03.2014, 16:02
please fix the following and create it that it senses us admins even when we're off duty.
Reward - +1 rep.
Код:
COMMAND:admins(playerid, params[]) { new string[1000]; foreach(Player, i) { if(IsOnDuty[i]) { if(P_Data[i][pAdmin] == 1) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 1 (Moderator)",GetName(i), i); } else if(P_Data[i][pAdmin] == 2) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 2 (Junior Admin)",GetName(i), i); } else if(P_Data[i][pAdmin] == 3) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 3 (Senior Admin)",GetName(i), i); } else if(P_Data[i][pAdmin] == 4) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 4 (Lead Admin)",GetName(i), i); } else if(P_Data[i][pAdmin] == 5) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 5 (Manager Admin)",GetName(i), i); } else if(P_Data[i][pAdmin] == 6) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 6 (Global Admin)",GetName(i), i); } else if(P_Data[i][pAdmin] == 7) { format(string,sizeof(string),""COL_BLUE"Admin %s (%d) - Level 7 (Server Owner)",GetName(i), i); } else return SCM(playerid,-1,""COL_MARONE"-No Administrator Are Online-"); SCM(playerid, -1, ""COL_GREEN"|_____________________________________________|"); SCM(playerid, -1, ""COL_YELLOW" Online Admins"); SCM(playerid,-1,string); SCM(playerid, -1, ""COL_GREEN"|_____________________________________________|"); }else return SCM(playerid,-1,""COL_MARONE"-No Administrators Are Online-"); } return 1;