我创建的python discord机器人无法与带有前缀>
的命令一起使用,例如
@client.command(name="say",description="Say the string follow by the
command",brief="Say command")
async def say(msg):
await client.say(msg)
当我有on_message函数时不起作用:
@client.event
async def on_message(message):
if message.author == client.user:
return
if message.content.startswith('hello'):
msg = 'Hello {0.author.mention}'.format(message)
await client.send_message(message.channel, msg)
机器人会回复hello
,但不会回复>say
有没有办法使两者同时工作?