我正在使用此命令对命令进行排队
@commands.max_concurrency(1, per=BucketType.guild, wait=True)
我有没有办法发送消息说你已经排队了
如果我将其设置为false,我可以发送一条错误消息,但用户将不得不再次发送该命令,因为它不会排队
@bot.event
async def on_command_error(context, error):
if isinstance(error, commands.MaxConcurrencyReached):
embed = discord.Embed(
title="Error!",
description="Please wait for the previous job to finish!",
color=0xE02B2B
)
await context.send(embed=embed)
我希望它发送一条消息“请等待上一个作业完成!”然后将其添加到队列中
目前没有回答
相关问题 更多 >
编程相关推荐