标签: python discord.py
我正在制作一个rpgbot,该角色在创建新角色时应该通过DM询问一些问题,但我遇到了问题。 当我使用message.content获取信息时,机器人会从服务器而不是DM读取消息。有人可以帮忙吗?
message.content
答案 0 :(得分:0)
使用
if not message.guild: <do stuff>
忽略公会中的消息