简体   繁体   English

机器人未正确发送自定义表情符号 discord.js

[英]Bot is not properly sending custom emojis discord.js

I'm having trouble using custom emoji in discord.js.我在 discord.js 中使用自定义表情符号时遇到问题。 When I try to make the bot use the emoji, It Always returns strange.当我尝试让机器人使用表情符号时,它总是返回奇怪。 Command Is: message.channel.send(':emoji name:emoji id') and When I try to use it, the bot responds with: :emoji name: .命令是: message.channel.send(':emoji name:emoji id')当我尝试使用它时,机器人会响应: :emoji name: But if I copy paste the :emoji name: It actually sends the emoji.但是,如果我复制粘贴:emoji name:它实际上会发送表情符号。

I tried with only the emoji id or only with :emoji name: and it still sends :emoji name: .我尝试仅使用emoji id或仅使用:emoji name:并且它仍然发送:emoji name: What can I do?我能做些什么?

have you tried doing this inside of discord...你试过在 discord 里面做这个吗……

\

and copy and paste it into your code?并将其复制并粘贴到您的代码中?

You would need to format the emoji like this:您需要像这样格式化表情符号:

<:emoji-name:emoji_id>

example:例子:

<:CL_Discord:929513964805685248>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM