Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var tmi = require('tmi.js');
- var options = {
- options: {
- debug: true
- },
- connection: {
- reconnect: true
- },
- identity: {
- username: "dulezite",
- password: "oauth:fag5yikmqisa3q8hfvn6wv7n7fem4r"
- },
- channels: ["fattypillow","elzic19","majkelgo","dulezite","nicprohubeny2","cyagonize","grolldir","will__x","majkkyna"]
- };
- var client = new tmi.client(options);
- client.connect();
- client.on("join", function (channel, username, self) {
- if(username != "Dulezite"){
- client.whisper(username,"Ahoj! Promin, ze rusim! Dej prosim follow na kanal prostehyklik! Dekuju!");
- }else console.log("Pripojeno.");
- });
- client.on('chat', function (channel, user, message, self) {
- if(message == "!test"){
- client.whisper(user.username,"Ahoj! Promin, ze rusim! Dej prosim follow na kanal prostehyklik! Dekuju!");
- }else if(message == "!tynus"){
- client.say(channel, "Gennia 2017: Nemam je umely!");
- }else if(message == "!cyagonize"){
- client.say(channel, "Cyagonize je typek! <3 <3 <3 <3 <3 <3 <3 <3 <3 <3 <3 <3 <3 ");
- }
- });
- client.on("timeout", function (channel, username, reason, duration) {
- client.say(channel,username+" byl docasne zabanovan na "+duration+" sekund za: "+reason);
- client.whisper(username,"Byl jsi docasne zabanovan na "+duration+" sekund za: "+reason);
- });
- client.on("ban", function (channel, username, reason) {
- if(reason != null){
- client.say(channel,"Uzivatel "+username+" byl zabanovan! Duvod: "+reason);
- }else{
- client.say(channel,"Uzivatel "+username+" byl zabanovan!");
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement