小编Jef*_*ang的帖子

discord.py 中的命令冷却时间

我希望我的不和谐机器人的命令有冷却时间。我尝试过其他方法,但似乎没有一个适合我所用的方法。

@client.event
async def on_message(message):
  if message.content == 'shear sheep':
    await message.channel.send('you sheared your sheep, gaining 1 wool.')
    #cooldown?
Run Code Online (Sandbox Code Playgroud)

python bots discord discord.py

0
推荐指数
1
解决办法
9433
查看次数

标签 统计

bots ×1

discord ×1

discord.py ×1

python ×1