From 81f006c571450ec09ddaf126aa78cfde775b9c1d Mon Sep 17 00:00:00 2001 From: Scab Date: Mon, 14 Oct 2024 10:27:12 -0400 Subject: [PATCH 1/5] added more slurs --- index.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/index.ts b/index.ts index 54eb09f..b6474ed 100644 --- a/index.ts +++ b/index.ts @@ -24,18 +24,18 @@ import { FluxDispatcher } from "@webpack/common"; /** * SEXUAL ***/ const badVerbsSexual = ["fuck", "cum"]; -const badNounsSexual = ["cunt", "yuri", "whore", "dick", "pussy", "slut", "tit", "cum", "cock", "blowjob", "sex", "ass", "furry", "bewbs", "boob", "booba", "boobies", "boobs", "booby", "porn", "pron", "pronhub", "r34", "rape", "raped", "raping", "rapist"]; +const badNounsSexual = ["cunt", "yuri", "whore", "dick", "penis", "bbc", "pussy", "pussyole", "slut", "tit", "cum", "cock", "blowjob", "sex", "ass", "furry", "bewbs", "boob", "booba", "boobies", "boobs", "booby", "porn", "pron", "pronhub", "xshare", "xhamster", "r34", "rape", "raped", "raping", "rapist", "womanizer", "nonce", "golden shower", "head"]; /** * FURRY ***/ -const badNounsFurry = ["", "meowing", "meow", "miau", "mreow", "mrow", "woof", "nya", ":pleading_catgirl", "purr", "oomf", "oomfie"]; +const badNounsFurry = ["", "meowing", "meow", "miau", "mreow", "mrow", "woof", "nya", ":pleading_catgirl", "purr", "oomf", "oomfie", "femboy"]; const badRegexesFurry = ["mr*eo*w+, mr+p, nya+, mrow+, purr+"]; /** * BRAINROT ***/ -const badNounsBrainrot = ["mewing", "mew", "skibidi", "gyat", "gyatt", "rizzler", "nettspend", "boykisser", "ohio", "rizz", "tickle my toes bruh", "crack my spine like a whip", "hawk tuah"]; +const badNounsBrainrot = ["mewing", "mew", "skibidi", "gyat", "gyatt", "rizzler", "nettspend", "boykisser", "ohio", "rizz", "tickle my toes bruh", "crack my spine like a whip", "hawk tuah", "pookie"]; /** * SLURS ***/ -const badNounsSlurs = ["retard", "faggot", "fag", "faggots", "fags", "retards", "n*g", "n*gg*", "n*gg*r"]; +const badNounsSlurs = ["retard", "retards", "retarded", "faggot", "fag", "faggots", "fags", "furfag", "tranny", "trannies", "n*g", "n*gg*", "n*gg*r", "n*glet", "ret*gga", "n*gtard", "n*g-nog", "n*gro", "gringo", "Yank"]; const badRegexesSlurs = ["\\bn{1,}(i|!|1){1,}(b|g){2,}(a|@|e|3){1,}?"]; /** * GENERAL ***/ const badVerbsGeneral = ["kill", "destroy"]; -const badNounsGeneral = ["shit", "bullshit", "bitch", "bastard", "die", "brainless"]; +const badNounsGeneral = ["shit", "bullshit", "bitch", "bastard", "die", "brainless", "moron", "dumb", "idiot"]; /** * FUN ***/ const badNounsFun = ["kotlin", "avast"]; /** * REPLACEMENTS ***/ From 4beec458501738834035c0406481edf7ea854990 Mon Sep 17 00:00:00 2001 From: nin0 Date: Sat, 19 Oct 2024 13:37:18 -0400 Subject: [PATCH 2/5] Update index.ts --- index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.ts b/index.ts index 54eb09f..6f0e02f 100644 --- a/index.ts +++ b/index.ts @@ -37,7 +37,7 @@ const badRegexesSlurs = ["\\bn{1,}(i|!|1){1,}(b|g){2,}(a|@|e|3){1,}?"]; const badVerbsGeneral = ["kill", "destroy"]; const badNounsGeneral = ["shit", "bullshit", "bitch", "bastard", "die", "brainless"]; /** * FUN ***/ -const badNounsFun = ["kotlin", "avast"]; +const badNounsFun = ["kotlin", "avast", "fres"]; /** * REPLACEMENTS ***/ const badVerbsReplacements = ["love", "eat", "deconstruct", "marry", "fart", "teach", "display", "plug", "explode", "undress", "finish", "freeze", "beat", "free", "brush", "allocate", "date", "melt", "breed", "educate", "injure", "change"]; const badNounsReplacements = ["pasta", "kebab", "cake", "potato", "woman", "computer", "java", "hamburger", "monster truck", "osu!", "Ukrainian ball in search of gas game", "Anime", "Anime girl", "good", "keyboard", "NVIDIA RTX 3090 Graphics Card", "storm", "queen", "single", "umbrella", "mosque", "physics", "bath", "virus", "bathroom", "mom", "owner", "airport", "Avast Antivirus Free"]; From d1611dd0b00d4710b0ab376d4ecca5952c63caea Mon Sep 17 00:00:00 2001 From: nin0 Date: Sat, 19 Oct 2024 17:43:42 -0400 Subject: [PATCH 3/5] Update index.ts --- index.ts | 9 --------- 1 file changed, 9 deletions(-) diff --git a/index.ts b/index.ts index 6f0e02f..8e394b5 100644 --- a/index.ts +++ b/index.ts @@ -25,9 +25,6 @@ import { FluxDispatcher } from "@webpack/common"; /** * SEXUAL ***/ const badVerbsSexual = ["fuck", "cum"]; const badNounsSexual = ["cunt", "yuri", "whore", "dick", "pussy", "slut", "tit", "cum", "cock", "blowjob", "sex", "ass", "furry", "bewbs", "boob", "booba", "boobies", "boobs", "booby", "porn", "pron", "pronhub", "r34", "rape", "raped", "raping", "rapist"]; -/** * FURRY ***/ -const badNounsFurry = ["", "meowing", "meow", "miau", "mreow", "mrow", "woof", "nya", ":pleading_catgirl", "purr", "oomf", "oomfie"]; -const badRegexesFurry = ["mr*eo*w+, mr+p, nya+, mrow+, purr+"]; /** * BRAINROT ***/ const badNounsBrainrot = ["mewing", "mew", "skibidi", "gyat", "gyatt", "rizzler", "nettspend", "boykisser", "ohio", "rizz", "tickle my toes bruh", "crack my spine like a whip", "hawk tuah"]; /** * SLURS ***/ @@ -58,11 +55,6 @@ export default definePlugin({ description: "Block sexual words/hornyspeak", default: true }, - blockFurryspeak: { - type: OptionType.BOOLEAN, - description: "Block furryspeak/meowing", - default: true - }, blockBrainrot: { type: OptionType.BOOLEAN, description: "Block things commonly said by Gen Alpha children", @@ -96,7 +88,6 @@ export default definePlugin({ getEnabledBadNouns() { const thingToReturn: string[] = []; if (this.settings.store.blockBrainrot) thingToReturn.push(...badNounsBrainrot); - if (this.settings.store.blockFurryspeak) thingToReturn.push(...badNounsFurry); if (this.settings.store.blockInsults) thingToReturn.push(...badNounsGeneral); if (this.settings.store.blockOthers) thingToReturn.push(...badNounsFun); if (this.settings.store.blockSexual) thingToReturn.push(...badNounsSexual); From b65f6b33efb2cafbd0db675f01f034137769b26b Mon Sep 17 00:00:00 2001 From: nin0dev Date: Thu, 23 Jan 2025 04:00:11 -0500 Subject: [PATCH 4/5] support managed APIs --- index.ts | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/index.ts b/index.ts index 8e394b5..406e420 100644 --- a/index.ts +++ b/index.ts @@ -16,7 +16,6 @@ * along with this program. If not, see . */ -import { addPreSendListener, removePreSendListener } from "@api/MessageEvents"; import { definePluginSettings } from "@api/Settings"; import { Devs } from "@utils/constants"; import definePlugin, { OptionType } from "@utils/types"; @@ -34,7 +33,7 @@ const badRegexesSlurs = ["\\bn{1,}(i|!|1){1,}(b|g){2,}(a|@|e|3){1,}?"]; const badVerbsGeneral = ["kill", "destroy"]; const badNounsGeneral = ["shit", "bullshit", "bitch", "bastard", "die", "brainless"]; /** * FUN ***/ -const badNounsFun = ["kotlin", "avast", "fres"]; +const badNounsFun = ["kotlin", "avast"]; /** * REPLACEMENTS ***/ const badVerbsReplacements = ["love", "eat", "deconstruct", "marry", "fart", "teach", "display", "plug", "explode", "undress", "finish", "freeze", "beat", "free", "brush", "allocate", "date", "melt", "breed", "educate", "injure", "change"]; const badNounsReplacements = ["pasta", "kebab", "cake", "potato", "woman", "computer", "java", "hamburger", "monster truck", "osu!", "Ukrainian ball in search of gas game", "Anime", "Anime girl", "good", "keyboard", "NVIDIA RTX 3090 Graphics Card", "storm", "queen", "single", "umbrella", "mosque", "physics", "bath", "virus", "bathroom", "mom", "owner", "airport", "Avast Antivirus Free"]; @@ -76,14 +75,10 @@ export default definePlugin({ default: true } }), - async start() { - this.preSend = addPreSendListener((_channelId, msg) => { - const newContent = this.replaceBadVerbs(this.replaceBadNouns(msg.content)); - msg.content = newContent; - }); - }, - stop() { - removePreSendListener(this.preSend); + onBeforeMessageSend: (c, msg) => { + // @ts-ignore + const newContent = this.replaceBadVerbs(this.replaceBadNouns(msg.content)); + msg.content = newContent; }, getEnabledBadNouns() { const thingToReturn: string[] = []; From e55d79519e401a1ae2b34b8c2797813babfec37e Mon Sep 17 00:00:00 2001 From: nin0dev Date: Mon, 10 Feb 2025 00:14:58 -0500 Subject: [PATCH 5/5] fixes --- index.ts | 55 ++++++++++++++++++++++++------------------------------- 1 file changed, 24 insertions(+), 31 deletions(-) diff --git a/index.ts b/index.ts index 406e420..8e3a5e2 100644 --- a/index.ts +++ b/index.ts @@ -1,20 +1,8 @@ /* - * Vencord, a modification for Discord's desktop app - * Copyright (c) 2024 nin0dev - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . -*/ + * Vencord, a Discord client mod + * Copyright (c) 2025 Vendicated and contributors + * SPDX-License-Identifier: GPL-3.0-or-later + */ import { definePluginSettings } from "@api/Settings"; import { Devs } from "@utils/constants"; @@ -113,8 +101,27 @@ export default definePlugin({ }, flux: { async MESSAGE_CREATE - ({ guildId, message }) { + ({ guildId, message }) { + if(Vencord.Plugins.plugins.GoodPerson.settings?.store.incoming) { + const msg = message; + // @ts-ignore + let newMessageContent = Vencord.Plugins.plugins.GoodPerson.replaceBadVerbs(Vencord.Plugins.plugins.GoodPerson.replaceBadNouns(msg.content)); + if (message.content !== newMessageContent) { + newMessageContent += "\n-# <:husk:1280158956341297225> **GoodPerson made this message good. Reload your client to clear changes**"; + msg.content = newMessageContent; + FluxDispatcher.dispatch({ + type: "MESSAGE_UPDATE", + message: msg, + guildId + }); + } + } + }, + async MESSAGE_UPDATE + ({ guildId, message }) { + if(Vencord.Plugins.plugins.GoodPerson.settings?.store.incoming) { const msg = message; + if(msg.content.includes("-# <:husk:1280158956341297225> **GoodPerson made this message good. Reload your client to clear changes**")) return; // @ts-ignore let newMessageContent = Vencord.Plugins.plugins.GoodPerson.replaceBadVerbs(Vencord.Plugins.plugins.GoodPerson.replaceBadNouns(msg.content)); if (message.content !== newMessageContent) { @@ -126,20 +133,6 @@ export default definePlugin({ guildId }); } - }, - async MESSAGE_UPDATE - ({ guildId, message }) { - const msg = message; - // @ts-ignore - let newMessageContent = Vencord.Plugins.plugins.GoodPerson.replaceBadVerbs(Vencord.Plugins.plugins.GoodPerson.replaceBadNouns(msg.content)); - if (message.content !== newMessageContent) { - newMessageContent += "\n-# <:husk:1280158956341297225> **GoodPerson made this message good. Reload your client to clear changes**"; - msg.content = newMessageContent; - FluxDispatcher.dispatch({ - type: "MESSAGE_UPDATE", - message: msg, - guildId - }); } } }