Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. ar tmi = require('tmi.js');
  2.  
  3. var options = {
  4. options: {
  5. debug: true
  6. },
  7. connection: {
  8. reconnect: true
  9. },
  10. identity: {
  11. username: "ExplosionBot",
  12. password: ""
  13. };
  14. channels: ["GamingExplosionTV"] // channels for bot to be in
  15. }
  16.  
  17. var client = new tmi.client(options); // Sets up the connection
  18.  
  19. client.connect(); //Connects to Twitch server
  20. client.on("chat", function (channel, userstate, message, self) {
  21. if (message === "!test") { // If user types !test
  22. client.say("GamingExplosionTV", "Testing command."); // trigger this command
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement