【发布时间】:2020-10-05 12:30:11
【问题描述】:
case 'test':
let timed = "10s"
const tests = new Discord.RichEmbed()
.setTitle("tets")
.setColor('#000000')
message.channel.send(tests);
setTimeout(function(){
tests.setColor('#5e4242')
}, ms(timed));
break;
所以我试图让嵌入的颜色在 10 秒后发生变化,这是一个测试命令,所以它被称为测试。我尝试了很多方法,我搜索了谷歌并显示了这一点,所以我决定尝试它,它完全没有做任何事情。我使用richembed 是因为当我使用messagemebed 时它显示客户端错误
【问题讨论】:
-
使用不同颜色的相同嵌入编辑消息。
MessageEmbed可能无法正常工作,因为您没有使用 Discord.js v12。
标签: javascript discord discord.js embed