Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const tmi = require('tmi.js');
- // Define configuration options
- const opts = {
- identity: {
- username: 'NICK WASZEGO BOTA ZOSTAW PRZECINEK I CUDZYSŁOWY',
- password: 'WASZ TOKEN AUTORYZACJI ZOSTAW TE JEBANE CUDZYSŁOWY'
- },
- channels: [
- 'NAZWA KANAŁU NA KTÓRYM BOT MA DZIAŁAĆ'
- ]
- };
- // Create a client with our options
- const client = new tmi.client(opts);
- // Register our event handlers (defined below)
- client.on('connected', onConnectedHandler);
- // Connect to Twitch:
- client.connect();
- function onConnectedHandler(addr, port) {
- client.action('NAZWA KANAŁU NA KTÓRYM BOT MA DZIAŁAĆ', `WIADOMOŚĆ NA CZACIE ${Math.floor(Math.random() * 10)}`);
- console.log(`* Connected to ${addr}:${port}`);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement