from discord.ext.commands import Bot
from discord.ext import commands
import asyncio
#TOKEN
TOKEN = "token"
client = discord.Client()
b = Bot(command_prefix = "!")
@b.event
async def on_ready():
print("on")
@b.event
async def on_message(message):
if "here" in message.content:
try:
await message.author.dm_channel.send("Message I choose")
except:
print('The DM could not be send due to privacy permissions')
b.run(TOKEN, bot = False)
所以我有这个自我机器人。基本上,它只是检查服务器上的人何时说“ @here”,它会自动以我选择的消息对他们进行dm处理。我只想知道如果有人说@here的速度更快,我将如何使这个自我机器人检查。