当我尝试:
await client.create_role(message.server, name='testrole', color=discord.Colour("FF0000"))
我收到此错误:
discord.errors.NotFound: NOT FOUND (status code: 404): Unknown Message
有谁知道如何获得有关此错误的更多信息?
答案 0 :(得分:3)
请勿将颜色作为字符串添加,并在前面添加0x
。所以改变
await client.create_role(message.server, name='testrole', color=discord.Colour("FF0000"))
向
await client.create_role(message.server, name='testrole', color=discord.Colour(0xFF0000))