I'm tired of this...

This commit is contained in:
Chloe Fontenot 🏳️‍⚧️ 2024-08-09 18:27:28 -05:00
parent f53f254800
commit b33c0a92ea

View File

@ -131,6 +131,9 @@ function replyMessage(message, correctedMessage, abbrsUsed) {
} }
client.on('messageCreate', message => { client.on('messageCreate', message => {
if (message.author.id == "1091120267851485215") {
return;
}
if (global.madlibState.gameChannel == message.channel.id && message.author.id != "1091120267851485215") { // Pass message to madlib game handler if message was sent in the active game channel. if (global.madlibState.gameChannel == message.channel.id && message.author.id != "1091120267851485215") { // Pass message to madlib game handler if message was sent in the active game channel.
madlibNextMessage(message.content, client); madlibNextMessage(message.content, client);
} }
@ -138,6 +141,7 @@ client.on('messageCreate', message => {
if (message != undefined) { if (message != undefined) {
colonThree(message); colonThree(message);
tylerStop(message); tylerStop(message);
clenseDegeneracy(message);
} }
}); });
@ -147,6 +151,7 @@ client.on('messageUpdate', (undefined, newMessage) => {
if (message != undefined) { if (message != undefined) {
colonThree(message); colonThree(message);
tylerStop(message); tylerStop(message);
clenseDegeneracy(message);
} }
}); });
@ -166,9 +171,7 @@ function getMatchingPhrase(inputString, targetCharacter) {
} }
global.colonThree = function colonThree(message) { global.colonThree = function colonThree(message) {
if (message.author.id == "1091120267851485215") {
return;
}
if (message.channel.id == "1253947401191034940" && !message.content.endsWith(":3")) { if (message.channel.id == "1253947401191034940" && !message.content.endsWith(":3")) {
const channel = client.channels.cache.get(message.channel.id); const channel = client.channels.cache.get(message.channel.id);
channel.send( "Your message does not end in :3."); channel.send( "Your message does not end in :3.");
@ -176,6 +179,11 @@ function getMatchingPhrase(inputString, targetCharacter) {
} }
} }
global.clenseDegeneracy = function clenseDegeneracy(message) {
if (message.content.contains("ussy") {
message.delete();
}
}
/* /*
Main bot logic. Check for abbreviations by splitting the message at any non-word characters, then if we find a match, create a new array, replace the abbreviation with the phrase, then call replyMessage() and reply to the original message with the corrected one. Main bot logic. Check for abbreviations by splitting the message at any non-word characters, then if we find a match, create a new array, replace the abbreviation with the phrase, then call replyMessage() and reply to the original message with the corrected one.
*/ */