From ec3c31df25128b87d8fc38e8054e6aa1b98c3267 Mon Sep 17 00:00:00 2001 From: Kofhisho Date: Wed, 16 Jul 2025 06:04:32 +0100 Subject: [PATCH] New Plugin: QuestFocused (#303) * Create index.tsx * Update constants.ts * Added missing styles * Revert "Added missing styles" This reverts commit 6d01e8b4dbfcf2262510bab62cc1a8b0b8a4c0a9. * Update README.md Added plugin to plugin list on README file * Update index.tsx --------- Co-authored-by: thororen <78185467+thororen1234@users.noreply.github.com> --- README.md | 1 + src/equicordplugins/questFocused/index.tsx | 39 ++++++++++++++++++++++ src/utils/constants.ts | 4 +++ 3 files changed, 44 insertions(+) create mode 100644 src/equicordplugins/questFocused/index.tsx diff --git a/README.md b/README.md index cd18e0017..55e828c6d 100644 --- a/README.md +++ b/README.md @@ -142,6 +142,7 @@ You can join our [discord server](https://discord.gg/equicord-117327988606502929 - PlatformSpoofer by Drag - PolishWording by Samwich - PurgeMessages by bhop & nyx +- QuestFocused by secp192k1 - QuestionMarkReplacement by nyx - Quoter by Samwich - RandomVoice by xijexo, omaw, thororen diff --git a/src/equicordplugins/questFocused/index.tsx b/src/equicordplugins/questFocused/index.tsx new file mode 100644 index 000000000..98bae610c --- /dev/null +++ b/src/equicordplugins/questFocused/index.tsx @@ -0,0 +1,39 @@ +/* + * Vencord, a Discord client mod + * Copyright (c) 2024 Vendicated and contributors + * SPDX-License-Identifier: GPL-3.0-or-later + */ + +import "@equicordplugins/_misc/styles.css"; + +import { EquicordDevs } from "@utils/constants"; +import definePlugin from "@utils/types"; +import { Forms } from "@webpack/common"; + +export default definePlugin({ + name: "QuestFocused", + description: "Prevent the quests player from pausing and possibly skip it all together.", + settingsAboutComponent: () => <> + + You might need to spam left mouse button on the video to skip it. + + , + authors: [EquicordDevs.secp192k1], + patches: [ + // Block pausing + { + find: "[QV] | updatePlayerState | playerState", + replacement: { + match: /(?<=case \i\.\i\.PAUSED:.{0,25})\i\.current\.pause\(\),/, + replace: "" + } + }, + { + find: "[QV] | updatePlayerState | playerState:", + replacement: { + match: /(?<=case \i\.\i\.PLAYING:)\i\.current\.paused/, + replace: "false" + } + }, + ], +}); diff --git a/src/utils/constants.ts b/src/utils/constants.ts index a0cf15e0e..14b74b821 100644 --- a/src/utils/constants.ts +++ b/src/utils/constants.ts @@ -1108,6 +1108,10 @@ export const EquicordDevs = Object.freeze({ veygax: { name: "veygax", id: 1119938236245094521n + }, + secp192k1: { + name: "secp192k1", + id: 477497542205243392n } } satisfies Record);