Quote:
Originally Posted by Eth
his old cmd:
pawn Код:
CMD:onduty(playerid, params[]) { SendClientMessage(playerid, COLOR_LIGHTSALMON, "____________Admins_On_Duty____________"); new totalonduty = 0; for(new i = 0; i < MAX_PLAYERS+1; i++) { if(pInfo[i][Admin] > 1){ if(aduty[i]){ totalonduty = totalonduty+1; new aname[MAX_PLAYER_NAME]; new alevel = pInfo[i][Admin]; new line[128]; GetPlayerName(i, aname, MAX_PLAYER_NAME); format(line, sizeof(line), "%s: Level %i Admin", aname, alevel); SendClientMessage(playerid, COLOR_LIGHTSALMON, line); } } } if(totalonduty == 0){ SendClientMessage(playerid, COLOR_RED, "There are no admins on duty."); } SendClientMessage(playerid, COLOR_RED, "_________________________________________"); return 1;
}
what i edit is aduty[i] his old one was : aduty[i] and i changed it to aduty[i] == 1 because this 1 will know if the player is on duty or not.
|
That didn't change anything. Still get the same result. If it helps, aduty[playerid] is set to false/true.