diff --git a/src/client.ts b/src/client.ts index b0fcfe4..f3770ef 100644 --- a/src/client.ts +++ b/src/client.ts @@ -84,7 +84,7 @@ export default class TClient extends Client { this.MPServerCache = {players: [], status: null, name: null} as MPServerCache; this.suggestion = new suggestion(this); this.repeatedMessages = {}; - this.setMaxListeners(20); + this.setMaxListeners(45); this.statsGraph = -60; } async init(){ diff --git a/src/events/messageCreate.ts b/src/events/messageCreate.ts index 348227f..9cc49af 100644 --- a/src/events/messageCreate.ts +++ b/src/events/messageCreate.ts @@ -3,7 +3,7 @@ import TClient from 'src/client'; export default { async run(client:TClient, message:Discord.Message){ if (message.author.bot || message.channel.type === Discord.ChannelType.DM) return; - const msgarr = message.content.toLowerCase().replaceAll(/[!@#$%^&*()_+\-=\[\]{};':"\\|,.<>\/?\n]/g, ' ').split(' '); + const msgarr = message.content.toLowerCase().replaceAll(/[!@#$%^&*()_+\-=\[\]{};':"\\|,.<>\/?\n?1234567890]/g, '').split(' '); let automodded: boolean; const Whitelist = [] // Array of channel ids for automod to be disabled in (Disables bannedWords and advertisement, mind you.)