From d29a36e5536c8a5771fd155d9992829c7d83a1d8 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Wed, 20 Mar 2024 01:17:12 -0400 Subject: [PATCH] Fix who-pokemon --- commands/games-sp/whos-that-pokemon.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/commands/games-sp/whos-that-pokemon.js b/commands/games-sp/whos-that-pokemon.js index d9631a44..e1eb6d7a 100644 --- a/commands/games-sp/whos-that-pokemon.js +++ b/commands/games-sp/whos-that-pokemon.js @@ -95,10 +95,10 @@ module.exports = class WhosThatPokemonCommand extends Command { const attachment = await this.createImage(data, true); const answerAttachment = await this.createImage(data, false); const connection = msg.guild ? getVoiceConnection(msg.guild.id) : null; + const resource = createAudioResource( + path.join(__dirname, '..', '..', 'assets', 'sounds', 'whos-that-pokemon.mp3') + ); if (msg.guild && connection && !this.client.dispatchers.has(msg.guild.id)) { - const resource = createAudioResource( - path.join(__dirname, '..', '..', 'assets', 'sounds', 'whos-that-pokemon.mp3') - ); const dispatcher = createAudioPlayer(); connection.subscribe(dispatcher); dispatcher.play(resource);