繁体   English   中英

Discord.js V14如何编辑已发送的嵌入?

[英]Discord.js V14 how to edit an embed already sent?

我在做一个假赠品系统,我需要用“赠品结束”嵌入消息示例编辑“赠品开始”嵌入消息

我找不到解决方案

您可以将消息存储在变量中,然后在需要时对其进行编辑。

const MSG = await message.channel.send({embeds: [yourEmbed]});

// Create a new Embed with which you're going to edit the message

const basicEmbed = new EmbedBuilder()
.setDescription("Example")

// Then edit your original message

MSG.edit({embeds: [basicEmbed}});

暂无
暂无

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

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