我有一个命令:
@bot.command(pass_context=True)
async def hellothere(ctx):
await Bot.say("Hello {}".format(ctx.message.author))
我想复制这个更短的命令。
I tried:
@bot.command(pass_context=True)
async def hello(ctx):
hellothere(ctx)
但我收到一条错误消息Command
不可调用。
有谁知道如何做到这一点?
@client.command(pass_context = True , aliases=['purge', 'clean', 'delete'])
只需更改别名即可。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)