Advertisement
Guest User

Untitled

a guest
May 30th, 2016
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. var tmi = require("tmi.js");
  2.  
  3. var clientOptions = {
  4. options: {
  5. debug: false
  6. },
  7. connection: {
  8. reconnect: true
  9. },
  10. identity: {
  11. username: "your-bot-username",
  12. password: "oauth:your-token"
  13. },
  14. channels: ["#schmoopiie"]
  15. };
  16.  
  17. var client = tmi.client(clientOptions);
  18.  
  19. client.connect();
  20.  
  21. client.on("join", function (channel, username) {
  22. if (username === clientOptions.identity.username.toLowerCase()) {
  23. console.log(client.userstate);
  24. }
  25. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement