tunes.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:csss-minion 作者: henrymzhao 项目源码 文件源码
def join(self, ctx, *, channel : discord.Channel):
        """Joins a voice channel."""
        if str(ctx.message.author.voice_channel) is not null or str(ctx.message.author.voice_channel.id) != self.bot.music_channel:
            await self.embed_for_me('I can only play in Music voicechannel. This is '+str(ctx.message.author.voice_channel),ctx)
            return False

        try:
            await self.create_voice_client(channel)
        except discord.ClientException:
            await self.embed_for_me('Already in a voice channel...',ctx)
        except discord.InvalidArgument:
            await self.embed_for_me('This is not a voice channel...',ctx)
        else:
            await self.embed_for_me('Ready to play audio in '+channel.name,ctx)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号