Discord Bot Maker

Discord Bot Maker

Ver estadísticas:
ethanlee3706 31 MAR 2023 a las 9:10
Cant send embed message in Run Script
Im having several problems trying to send my embed via a run script, everything I have tried returns an error, can anyone direct me on how to create this sort of function.
Última edición por ethanlee3706; 31 MAR 2023 a las 9:43
< >
Mostrando 1-1 de 1 comentarios
TMGiorgio 2 ABR 2023 a las 23:16 
can u give me the raw data so i can look thru and see what the problem is, i will then looks for the problem and send you the solution as well a guid on how to fix it.


To send an embed message in the "Run Script too" feature, you can use the Discord.js library.

Here's an example code snippet that you can use in the "Run Script too" feature to send an embed message:

---------------------------------------------------------------------
csharp

const Discord = require('discord.js');
const embed = new Discord.MessageEmbed()
.setColor('#0099ff')
.setTitle('Example Embed')
.setDescription('This is an example embed message.');

const channel = client.channels.cache.get('YOUR_CHANNEL_ID');
if (channel) {
channel.send(embed);
}
------------------------------------------------------------------

Make sure to replace 'YOUR_CHANNEL_ID' with the actual ID of the channel where you want to send the message.
< >
Mostrando 1-1 de 1 comentarios
Por página: 1530 50