SyntaxIsHere

Untitled

Dec 23rd, 2017
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.85 KB | None | 0 0
  1. const Discord = require("discord.js");
  2. const client = new Discord.Client();
  3.  
  4. client.on("ready", () => {
  5. client.user.setGame('!help | Syntax Helper')
  6. console.log("Server Connection Recieved");
  7. console.log("Sending Packets To Discord...");
  8. console.log("Adding Bot To Server Connection");
  9. console.log("Status: Complete");
  10. console.log("Syntax Helper Online");
  11. });
  12. function doMagic8BallVoodoo() {
  13. var rand = [' Absolutly.', ' Absolutly not.', ' It is true.', ' Impossible.', ' Of course.', ' I do not think so.', ' It is true.', ' It is not true.', ' I am very undoubtful of that.', ' I am very doubtful of that.', ' Sources point to no.', ' Theories prove it.', ' Reply hazy try again', ' Ask again later', ' Better not tell you now', ' Cannot predict now', ' Concentrate and ask again'];
  14.  
  15. return rand[Math.floor(Math.random()*rand.length)];
  16. }
  17.  
  18. function doPing() {
  19. var rand = ['**Pinged To Server**',
  20. '**Pinged To Syntax Helper**',
  21. '**Instant Ping**',
  22. ':ping_pong: ']
  23. return rand[Math.floor(Math.random()*rand.length)];
  24. }
  25.  
  26.  
  27.  
  28.  
  29.  
  30. client.on("message", (message) => {
  31. if (message.content.startsWith("!8ball")) {
  32. message.channel.send(doMagic8BallVoodoo());
  33. }
  34. if (message.content.startsWith("!help")) {
  35. message.channel.send("**Hey, Our Temporary Commands List Can Be Found At https://pastebin.com/raw/S6tANnGP , Soon We Will Have A Wesbite With All The Commands!**");
  36. }
  37. if (message.content.startsWith("!ping")) {
  38. message.channel.send({embed: {
  39. color: 3447003,
  40. description: doPing()
  41. }});
  42. }
  43. if (message.content.startsWith("!kick")) {
  44. if (message.author.hasPermission("kickMember")) {
  45. let MessageUser = message.guild.member(message.mentions.users.first());
  46. var args = message.content.split(" ").slice(1);
  47. let Reason = args[3]
  48. MessageUser.kick(Reason);
  49. }}
  50. });
  51.  
  52.  
  53. client.login("n0");
Advertisement
Add Comment
Please, Sign In to add comment