From ef236fa9648ac7d1f45ad061390278c5f3969d42 Mon Sep 17 00:00:00 2001 From: brandons209 Date: Sun, 28 Jun 2020 00:39:51 -0400 Subject: [PATCH] ensure bot is out of VC before using sfx so it queues properly --- sfx/sfx.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sfx/sfx.py b/sfx/sfx.py index f20e1bd..59d0274 100644 --- a/sfx/sfx.py +++ b/sfx/sfx.py @@ -281,10 +281,16 @@ class SFX(commands.Cog): """ Play a say sound! """ + # TODO: cost manager receipt integration if not ctx.author.voice or ctx.author.voice.channel is None: await ctx.send(error("Connect to a voice channel to use this command.")) return + # TODO: create my own queue to fix this issue + if ctx.guild.me.voice and ctx.guild.me.voice.channel != ctx.author.voice.channel: + await ctx.send(error("Please wait for the bot to disconnect from it's VC before using the command.")) + return + name = name.lower() saysounds = await self.config.guild(ctx.guild).saysounds() audio_cog = self.bot.get_cog("Audio")