Update 'node/boto.js'

This commit is contained in:
Sarimoko 2022-02-11 06:31:26 +00:00
parent e026bc17ad
commit 7ad6682f6a
1 changed files with 18 additions and 10 deletions

View File

@ -25,7 +25,12 @@ client.on('message', (channel, tags, message, self) => {
const isMod = badges.moderator;
const isModUp = isBroadcaster || isMod;
});
// R E A C T I V E
let isMod = user.mod || user['user-type'] === 'mod';
let isBroadcaster = channel.slice(1) === user.username;
let isModUp = isMod || isBroadcaster;
// START of REACTIVE
// ==================================
client.on("anongiftpaidupgrade", (channel, username, userstate) => {
// Do your stuff.
@ -54,11 +59,11 @@ client.on("hosting", (channel, target, viewers) => {
});
// User joins/connects
client.on("join", (channel, username, self) => {
client.say(channel, `/me +1 Chatter! Viewer or Bot...? Time will tell!`);
// client.say(channel, `/me +1 Chatter! Viewer or Bot...? Time will tell!`);
});
// Bye Felicia!
client.on("part", (channel, username, self) => {
client.say(channel, `/me -1 Chatter! Where's my bounty hunters? Essemble the *air-qoutes* search-party *air-qoutes*`);
// client.say(channel, `/me -1 Chatter! Where's my bounty hunters? Essemble the *air-qoutes* search-party *air-qoutes*`);
});
// Incoming Raid
client.on("raided", (channel, username, viewers) => {
@ -79,15 +84,16 @@ client.on("resub", function (channel, username, months, message, userstate, meth
});
client.on("subscription", function (channel, username, method, message, userstate) {
// Do your stuff.
client.say(channel, `/me SUB Test`);
client.say(channel, `/me BLEEP! BLOOP! +1 Subscriber, thank you very much! MOTE-SPAM!`);
client.say(channel, `!kappagen sarimoKO sarimoNERD`);
});
client.on("whisper", (from, userstate, message, self) => {
// Don't listen to my own messages..
if (self) return;
// Do your stuff.
client.say(channel, `/me Bleep! Bloop! Sext message recieved!`);
//client.say(channel, `/me Bleep! Bloop! Sext message recieved!`);
});
// END of REACTIVE
// ==================================
// !COMMANDS
// ==================================
@ -114,9 +120,11 @@ client.on('message', (channel, tags, message, self) => {
//let isMod = user.mod || user['user-type'] === 'mod';
//let isBroadcaster = channel.slice(1) === user.username;
//let isModUp = isMod || isBroadcaster;
//if(isModUp) {
// Something for moderators or higher
//}
if(isModUp) {
if(command === 'mod') {
client.say(channel, `Mod test command`);
}
}
// I N F O
// ==================================