Advertisement
Earthcomputer

retard.js

Sep 1st, 2018
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var args = message.getContent().split(" ");
  2. if (args.length < 2) {
  3.     channel.message("Wrong command, you retard, try //retards");
  4.     return;
  5. }
  6.  
  7. var user = args[1];
  8. if (!user.startsWith("<") || !user.endsWith(">")) {
  9.     channel.message("Ping them!");
  10.     return;
  11. }
  12. user = user.substring(1, user.length - 1);
  13. if (!user.startsWith("@")) {
  14.     channel.message("Ping them!");
  15.     return;
  16. }
  17. user = user.substring(1);
  18. if (user.startsWith("!"))
  19.     user = user.substring(1);
  20.  
  21. var userObj = guild.getUser(user);
  22. if (!userObj) {
  23.     channel.message("Noone is a retard!");
  24.     return;
  25. }
  26.  
  27. manager.addRole(userObj, guild.getRole("478235767836246017"));
  28. channel.message("We have one more retard on this planet!");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement