03.11.2012, 10:19
what is the afk system that when u /afk take u to lv and change word and put near ur name [AFK]_%s
new playerAFK[MAX_PLAYERS]; new playerAFKTime[MAX_PLAYERS];
playerAFKTime[playerid] = 0; playerAFK[playerid] = 0;
CMD:afk(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 2) { new szMessage[36 + MAX_PLAYER_NAME]; SendClientMessageEx(playerid,COLOR_WHITE,"Listing all AFK players..."); foreach(Player, i) if(playerAFK[i] != 0 && playerAFKTime[i] > 60) { format(szMessage,sizeof(szMessage),"* %s (ID %d), AFK for %d minutes.", GetPlayerNameEx(i), i, playerAFKTime[i] / 60); if(PlayerInfo[i][pAdmin] >= 2) SendClientMessageEx(playerid,COLOR_RED,szMessage); else SendClientMessageEx(playerid,COLOR_GREY,szMessage); } } else SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use this command."); return 1; }