Answer the question
In order to leave comments, you need to log in
How to connect two functions?
There is a code that will respond to the command. How can I make sure that the response to this command is in the embed message? That is, how to connect two functions in message.send?
robot.on('message', message => {
if (message.content.toLowerCase() === '!habr') {
message.channel.send('answer.');
}
});
const exampleEmbed = new Discord.MessageEmbed()
.setTitle('Marasite Support')
.setColor('#DC143C')
.setDescription('Какое-то описание чего-то.');
Answer the question
In order to leave comments, you need to log in
Of course, I understand that no one wants to learn a language before writing bots, but this is already getting out of the scope of what is allowed.
this is not your first question in a week of such content.
if you do not start learning the language, your questions will be deleted, because "The answer is easily searched by the search engine", so draw your own conclusions.
robot.on('message', message => {
if (message.content.toLowerCase() === '!habr') {
const exampleEmbed = new Discord.MessageEmbed()
.setTitle('Marasite Support')
.setColor('#DC143C')
.setDescription('Какое-то описание чего-то.');
message.channel.send(exampleEmbed);
}
});
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question