|
|
@ -104,10 +104,12 @@ function replyMessage(message, correctedMessage, abbrsUsed) {
|
|
|
|
|
|
|
|
|
|
|
|
client.on('messageCreate', message => {
|
|
|
|
client.on('messageCreate', message => {
|
|
|
|
checkMessage(message);
|
|
|
|
checkMessage(message);
|
|
|
|
|
|
|
|
checkInsult(message);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
client.on('messageUpdate', (undefined, newMessage) => {
|
|
|
|
client.on('messageUpdate', (undefined, newMessage) => {
|
|
|
|
checkMessage(newMessage);
|
|
|
|
checkMessage(newMessage);
|
|
|
|
|
|
|
|
checkInsult(newMessage);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
function checkMessage(message) {
|
|
|
|
function checkMessage(message) {
|
|
|
@ -173,3 +175,12 @@ function checkMessage(message) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function checkInsult(message) {
|
|
|
|
|
|
|
|
if (message.content.includes("bot", "annoying") || message.content.includes("bad")) {
|
|
|
|
|
|
|
|
message.react('🇳');
|
|
|
|
|
|
|
|
message.react('🇴');
|
|
|
|
|
|
|
|
message.react('❌');
|
|
|
|
|
|
|
|
message.react('🇺');
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|