aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAnimal <24845294+ItzOnlyAnimal@users.noreply.github.com>2022-10-19 17:28:02 -0400
committerGitHub <noreply@github.com>2022-10-19 23:28:02 +0200
commitf81ab5ef93459baf0a45eec1264412144dc4a18c (patch)
treed84ee670f6b78727dfe932f2ae1e3f22124677ce /src
parent1f50f78912caeeff1c65182d61b72e6ec95b9899 (diff)
downloadVencord-f81ab5ef93459baf0a45eec1264412144dc4a18c.tar.gz
Vencord-f81ab5ef93459baf0a45eec1264412144dc4a18c.tar.bz2
Vencord-f81ab5ef93459baf0a45eec1264412144dc4a18c.zip
Add volume settings to fart plugin (#113)
Co-authored-by: Ven <vendicated@riseup.net>
Diffstat (limited to 'src')
-rw-r--r--src/plugins/fart.ts18
1 files changed, 14 insertions, 4 deletions
diff --git a/src/plugins/fart.ts b/src/plugins/fart.ts
index 872977d..7a40afa 100644
--- a/src/plugins/fart.ts
+++ b/src/plugins/fart.ts
@@ -1,7 +1,8 @@
import { ApplicationCommandOptionType } from "../api/Commands";
+import { makeRange } from "../components/PluginSettings/components";
import { Devs } from "../utils/constants";
-import definePlugin from "../utils/types";
-import { makeLazy } from "../utils/misc";
+import definePlugin, { OptionType } from "../utils/types";
+import { Settings } from "../Vencord";
export default definePlugin({
name: "Fart2",
@@ -22,12 +23,21 @@ export default definePlugin({
execute(args) {
const fart = new Audio("https://raw.githubusercontent.com/ItzOnlyAnimal/AliuPlugins/main/fart.mp3");
- fart.volume = 0.3;
+ fart.volume = Settings.plugins.Fart2.volume;
fart.play();
return {
content: (args[0]) ? `<@${args[0].value}> fart` : "fart"
};
},
- }]
+ }],
+ options: {
+ volume: {
+ description: "how loud you wanna fart (aka volume)",
+ type: OptionType.SLIDER,
+ markers: makeRange(0, 1, 0.1),
+ default: 0.5,
+ stickToMarkers: false,
+ }
+ }
});