因此,当前,当我在机器人上使用ban命令时,它在当前频道中说它禁止了该用户,但是我将如何使该机器人在另一个频道(如日志频道)中这样说呢? 我当前的禁止代码是
@bot.command(pass_context=True)
async def ban(ctx, member: discord.Member, message):
if ctx.message.author.server_permissions.ban_members:
embed=discord.Embed(title="You have been banned from Roblox Gang", description=message, color=0x00ff00f6)
await bot.send_message(member, embed=embed)
await bot.ban(member)
await bot.say("{0} has been banned for {1}".format(member, message))
else:
await bot.say("Permission Denied")