Advertisement
Guest User

Untitled

a guest
Nov 27th, 2014
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.92 KB | None | 0 0
  1. CMD:hide(playerid)
  2. {
  3. if(pAdmin[playerid] < 1)
  4. return Error(playerid, "You are not authorized to use this command!");
  5. if(pHidden[playerid] == 0)
  6. {
  7. pHidden[playerid] = 1;
  8. format(str, sizeof(str), ""RED_E"* ADMIN-MSG: "GREY_E"%s(%i) has hidden himself from the admin list.", pName[playerid], playerid);
  9. SendAdminMessage(COLOR_GREY, str);
  10. SendClientMessage(playerid, COLOR_YELLOW, "- AS - "RED_E"You have hidden yourself from the admin list!");
  11. SendClientMessage(playerid, COLOR_YELLOW, "- AS - "RED_E"Type /hide again to display yourself on the list.");
  12. }
  13. else
  14. {
  15. pHidden[playerid] = 0;
  16. SendClientMessage(playerid, COLOR_YELLOW, "- AS - "GREEN_E"You will now be displayed on the admin list!");
  17.  
  18. if(pLogged[playerid] == true)
  19. {
  20. format(query, sizeof(query), "UPDATE players SET hidden=%d WHERE reg_id=%d", pHidden[playerid], pRegID[playerid]);
  21. MySQL_updateQuery(query);
  22. }
  23. return true;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement