Answer the question
In order to leave comments, you need to log in
Discord.py how to check if a message is sent from the author?
I made a command, I want to make a confirmation for it. That is, the bot asks something and waits for an answer. How to make the bot process the response as a message ONLY from the author who wrote the command
Answer the question
In order to leave comments, you need to log in
Client.wait_for(event, *, check, timeout)
: https://discordpy.readthedocs.io/en/stable/api.htm...
def check(message):
return message.author.id == ctx.author.id
try:
m = await bot.wait_for("message", check=check, timeout = 30)
except asyncio.TimeoutError:
pass
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question