Advertisement
Guest User

Untitled

a guest
Dec 4th, 2016
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.75 KB | None | 0 0
  1. var options = {
  2. options: {
  3. debug: true
  4. },
  5. connection: {
  6. cluster: "aws",
  7. reconnect: true
  8. },
  9. identity: {
  10. username: "Wulfy_zef",
  11. password: "oauth:VoHiYo"
  12. },
  13. channels: [channel]
  14. }
  15.  
  16.  
  17. var client = new tmi.client(options);
  18. client.connect();
  19.  
  20. client.on('connected', function(address, port) {
  21. });
  22.  
  23.  
  24. var options2 = {
  25. options: {
  26. debug: true
  27. },
  28. connection: {
  29. cluster: "aws",
  30. reconnect: true
  31. },
  32. identity: {
  33. username: "Wulfyzef",
  34. password: "oauth:VoHiYo"
  35. },
  36. channels: [channel]
  37. }
  38.  
  39.  
  40. var client2 = new tmi.client(options2);
  41. client2.connect();
  42.  
  43. client2.on('connected', function(address, port) {
  44. });
  45.  
  46.  
  47. var owner = "Wulfy_Zef";
  48. var hype = 1;
  49.  
  50. function commands (channel, user, message, self) {
  51.  
  52. if (message.startsWith("z!k") && user['display-name'] == owner) {
  53. hype = false;
  54. }
  55. else if(message.includes("z!hype") && !message.includes("!z!hype") && user['display-name'] == owner) {
  56. if(listentoanyone || user.mod) {
  57. hype = 1;
  58. var tmp_msg = message.split("z!")[1];
  59. var timer = tmp_msg.split(" ")[1];
  60. notifier.notify(tmp_msg.split(" ")[1]);
  61. setTimeout(excuteMethod, 1000);
  62. function excuteMethod () {
  63. client.whisper("TTDBot", "!p !pd !p !pd !p !pd !p !pd !p !pd !p !pd");
  64. timer--;
  65. if (timer >= 0 && hype) setTimeout(excuteMethod, 1000);
  66. }
  67. }
  68. }
  69.  
  70. }
  71.  
  72.  
  73.  
  74.  
  75. client.on('chat', commands(channel, user, message, self));
  76. client2.on('chat', commands(channel, user, message, self));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement