Advertisement
Guest User

DMreport by vinz

a guest
Feb 1st, 2014
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. #include <ZCMD>
  2. #include <a_samp>
  3. #include <sscanf2>
  4. #include <foreach>
  5.  
  6. stock ABroadCast(color,string[],level)
  7. {
  8. foreach(Player, i)
  9. {
  10. if (PlayerInfo[i][pAdmin] >= level && PlayerInfo[i][pTogReports] != 1)
  11. {
  12. SendClientMessageEx(i, color, string);
  13. //printf("%s", string);
  14. }
  15. }
  16. return 1;
  17. }
  18. CMD:dmreport(playerid, params[])
  19. {
  20. new giveplayerid, string[128];
  21. if(//your admin enums //)
  22. {
  23. SendClientMessageEx(playerid, COLOR_GRAD2, "You can't submit reports as an administrator.");
  24. return 1;
  25. }
  26. if(sscanf(params, "u", giveplayerid)) return SendClientMessageEx(playerid, COLOR_WHITE, "USAGE: /dmreport [playerid]");
  27. format(string, sizeof(string), "%s [ID %d] has reported a possible DM by ID %d. check /kills ", GetPlayerNameEx(playerid),playerid,giveplayerid);
  28. ABroadCast(COLOR_RED, string, 2);
  29. SendClientMessageEx(playerid, COLOR_YELLOW, "Your report message was sent to the Admins.");
  30. return 1;
  31. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement