Plugin
SpotifyCrack
Free listen along, no auto-pausing in voice chat, and allows activity to continue playing when idling
1
/*2
* FiveCord — a Discord client mod3
* Copyright (c) 2025 FiveCord4
* SPDX-License-Identifier: GPL-3.0-or-later5
*/6
7
import { definePluginSettings } from "@api/Settings";8
import { Devs } from "@utils/constants";9
import definePlugin, { OptionType } from "@utils/types";10
11
const settings = definePluginSettings({12
noSpotifyAutoPause: {13
description: "Disable Spotify auto-pause",14
type: OptionType.BOOLEAN,15
default: true,16
restartNeeded: true17
},18
keepSpotifyActivityOnIdle: {19
description: "Keep Spotify activity playing when idling",20
type: OptionType.BOOLEAN,21
default: false,22
restartNeeded: true23
}24
});25
26
export default definePlugin({27
name: "SpotifyCrack",28
description: "Free listen along, no auto-pausing in voice chat, and allows activity to continue playing when idling",29
tags: ["Media", "Utility", "Activity"],30
authors: [Devs.Cyn, Devs.Nuckyz],31
settings,32
33
patches: [34
{35
36
find: 039;dispatch({type:"SPOTIFY_PROFILE_UPDATE"039;,37
replacement: {38
match: /SPOTIFY_PROFILE_UPDATE.+?isPremium:(?="premium"===(\i)\.body\.product)/,39
replace: (m, req) => `${m}(${req}.body.product="premium")&&`40
},41
},42
{43
find: "}getPlayableComputerDevices(){",44
replacement: [45
{46
predicate: () => settings.store.noSpotifyAutoPause,47
match: /(?<=function \i\(\){)(?=.{0,200}SPOTIFY_AUTO_PAUSED\))/,48
replace: "return;"49
},50
{51
predicate: () => settings.store.keepSpotifyActivityOnIdle,52
match: /(shouldShowActivity\(\){.{0,50})&&!\i\.\i\.isIdle\(\)/,53
replace: "$1"54
}55
]56
}57
]58
});59