Score_

Untitled

Aug 6th, 2018
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.40 KB | None | 0 0
  1. CMD:admins(playerid,params[])
  2. {
  3. if(CosminInfo[playerid][pVIP] < 1) return
  4. SendClientMessage( playerid, COLOR_ULTRARED, "ERROR: You need VIP rank to use this command." );
  5. //--------------------------------------------------------------------------
  6. new OnAdmns = 0, astr[4096], arank[50], TotalCount, DCaption[128];
  7. //--------------------------------------------------------------------------
  8. for(new i = 0; i < MAX_PLAYERS; i++)
  9. {
  10. if(IsPlayerConnected(i) && CosminInfo[i][Level] > 0)
  11. {
  12. if(CosminInfo[i][Hidden] == 0)
  13. {
  14. //--------------------------------------------------------------
  15. else if(IsPlayerAdmin(i) && CosminInfo[i][AFKBRB] == 0) arank = "{FF0000}({FFFFFF}RCON{FF0000})";
  16. else if(CosminInfo[i][AFKBRB] >= 1) arank = "{26FF00}(AFK/BRB)";
  17. else if(CosminInfo[i][AFKBRB] == 0 && !IsPlayerAdmin(i)) arank = "";
  18. //--------------------------------------------------------------
  19. format(astr, sizeof(astr), "{FF0000}%s {15FF00}(ID:%d){00BBF6} Level: %d %s\n%s", PlayerName(i), i, CosminInfo[i][Level], arank, astr);
  20. OnAdmns++;
  21. }
  22. if(CosminInfo[i][Hidden] == 1 && CosminInfo[playerid][Level] >= 1)
  23. {
  24. //--------------------------------------------------------------
  25. else if(CosminInfo[i][Hidden] == 1) arank = "{FF0000}(Hidden)";
  26. else if(IsPlayerAdmin(i) && CosminInfo[i][AFKBRB] == 0) arank = "{FF0000}({FFFFFF}RCON{FF0000})";
  27. else if(CosminInfo[i][AFKBRB] >= 3) arank = "{26FF00}(AFK/BRB)";
  28. else if(CosminInfo[i][AFKBRB] == 0 && !IsPlayerAdmin(i)) arank = "";
  29. //--------------------------------------------------------------
  30. format(astr, sizeof(astr), "{FF0000}%s {15FF00}(ID:%d){00BBF6} Level: {33FFFF}%d %s\n%s", PlayerName(i), i, CosminInfo[i][Level], arank, astr);
  31. OnAdmns++;
  32. }
  33. TotalCount++;
  34. }
  35. }
  36. //--------------------------------------------------------------------------
  37. format(DCaption, 128, "Admin(s) (Online: {FF0000}%d{AFAFAF})", TotalCount);
  38. //--------------------------------------------------------------------------
  39. if(OnAdmns == 0) return
  40. GameTextForPlayer(playerid, "~w~~h~No ~r~~h~Admins~w~~h~ Online!", 3000, 4);
  41. //--------------------------------------------------------------------------
  42. else return ShowPlayerDialog(playerid, 1707, DIALOG_STYLE_LIST, DCaption, astr, "Ok", "");
  43. }
Advertisement
Add Comment
Please, Sign In to add comment