Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CMD:admins(playerid,params[])
- {
- new Count = 0;
- new n[MAX_PLAYER_NAME];
- new string[1000];
- for(new i = 0; i < MAX_PLAYERS; i++)
- {
- if(!IsPlayerConnected(i)) continue;
- if(PlayerInfo[i][Level] < 1) continue;
- GetPlayerName(i,n,sizeof(n));
- format(string,sizeof(string),"{FF0000}%sLevel %d: {C0C0C0}%s {FF00}(%d) {00FFFF}[%s]{FF0000}\n", string, PlayerInfo[i][Level], n, i, GetRankFromLevel(i));
- Count++;
- }
- if(Count == 0)
- {
- ShowPlayerDialog(playerid, 2,DIALOG_STYLE_MSGBOX, "{00FFFF} {33FF33}Online Admin...", "Tidak Ada Admin Yang Online", "ok", "");
- return 1;
- }
- ShowPlayerDialog(playerid, 2,DIALOG_STYLE_MSGBOX, "{00FFFF} {33FF33}Online Admin...", string, "ok", "");
- return 1;
- }
- stock GetRankFromLevel(playerid)
- {
- new Rank[40];
- switch(PlayerInfo[playerid][Level])
- {
- case 0:
- {
- Rank = "Regular Player";
- }
- case 1:
- {
- Rank = " {C0C0C0}Newbie Administrator";
- }
- case 2:
- {
- Rank = " {C0C0C0}Moderator";
- }
- case 3:
- {
- Rank = " {C0C0C0}Higher Administrator";
- }
- case 4:
- {
- Rank = " {C0C0C0}Profesional Administrator";
- }
- case 5:
- {
- Rank = " {C0C0C0}Elite Administrator";
- }
- case 10:
- {
- Rank = " {C0C0C0}Srv. Co.Owner";
- }
- case 100:
- {
- Rank = " {C0C0C0}Executive Administrator";
- }
- }
- return Rank;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement