Advertisement
Guest User

Pongobot kod

a guest
May 27th, 2016
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. var tmi = require('tmi.js');
  2.  
  3. var silent = true;
  4. var options = {
  5. options: {
  6. debug: true
  7. },
  8. connection: {
  9. cluster: "aws",
  10. reconnect: true
  11. },
  12. identity: {
  13. username: "",
  14. password: ""
  15. },
  16. channels: ["Cliff122", "STAMSITE", "FragtaleTV", "pajlada"]
  17. }
  18.  
  19. var client = new tmi.client(options);
  20. client.connect();
  21.  
  22. client.on('connected', function(address, port) {
  23. if (silent != true) {
  24. client.action("Cliff122", " joined the channel!");
  25. client.action("STAMSITE", " joined the channel!");
  26. client.action("FragtaleTV", " joined the channel!");
  27. client.action("pajlada", " joined the channel!");
  28. }
  29. });
  30.  
  31. client.on("chat", function (channel, user, message, self) {
  32. if (channel == "#stamsite" && user["display-name"] == "STAMSITE") {
  33. if(message.substring(0,2) == "<3" && message.substring(message.length-2) == "<3") {
  34. client.say(channel, message);
  35. }
  36. }
  37. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement