【发布时间】:2020-02-26 05:25:37
【问题描述】:
我正在尝试制作一个机器人,列出各种自定义表情符号及其含义。我的代码:
await message.channel.send(":up10: means the stock price has gone up more than 10% in the last 24 hours")
这应该显示一个表情符号来代替 :up10: 但它所做的只是打印文字文本。
【问题讨论】:
我正在尝试制作一个机器人,列出各种自定义表情符号及其含义。我的代码:
await message.channel.send(":up10: means the stock price has gone up more than 10% in the last 24 hours")
这应该显示一个表情符号来代替 :up10: 但它所做的只是打印文字文本。
【问题讨论】:
您需要格式化表情符号字符串以说明 12345 是表情符号的 ID。
如果你想找回你的 emoji ID,请在聊天中发送 :up10: ,你的 discord 客户端会将其更改为:<:up10:12345>
您需要发送他们给您的全部内容:
await message.channel.send("<:up10:12345> is the emoji...")
(注意你的ID会比12345长很多)
【讨论】:
discord.Guild.emojis。