[英]how to set an invisible status using discord.py
async def shutdown(ctx):
if ctx.message.author.name == 'LouieMartin':
await ctx.send('Shutting down...')
await client.change_presence(status=discord.Status.invisible)
quit()
The problem is the await client.change_presence(status=discord.Status.invisible)
.问题是
await client.change_presence(status=discord.Status.invisible)
。
There are no problem solutions that I can think of.没有我能想到的问题解决方案。
I think that it would be...我认为这将是...
await client.change_presence(status=discord.Status.offline)
instead of...代替...
await bot.change_presence(status=discord.Status.invisible)
This worked for my bot.这对我的机器人有用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.