【发布时间】:2019-02-16 02:50:57
【问题描述】:
所以我已经在这个机器人上工作了一段时间,但我无法让它通过命令发送嵌入图片。如果有人可以帮助我,我将非常感激。这是代码:
if message.content.upper().startswith('!PNG'):
role = get(message.server.roles, id="517064875134943262")
userID = message.author.id
e = discord.Embed()
e.set_image(url="https://i.imgur.com/5nqpFiF.jpg")
if not "343249790047485952" in [role.id for role in message.author.roles]:
await client.send_message(message.channel, 'Insufficient Permissions.')
else:
await client.send_message(message.channel, e)
这就是我在 Discord 上得到的:
discord.embeds.Embed 对象位于 0x000000010377EEE
【问题讨论】:
标签: python python-3.x discord.py