Z
Z
Zakkaru2021-08-11 22:44:13
Python
Zakkaru, 2021-08-11 22:44:13

How can I make a command to select a random Embed message?

Complete zero, help, I don't know how to make a random in Embed

Answer the question

In order to leave comments, you need to log in

1 answer(s)
G
getaxe, 2021-08-11
@Zakkaru

const RANDOM = [
  'Фраза 1',
  'Фраза 2'
];

let embed = new Discord.MessageEmbed()
    embed.setDescription(`**
        ${RANDOM[getRandomInt(RANDOM.length)]}
    **`) 
    .setColor('RANDOM')
    message.channel.send(embed)
    }

ps All this naturally needs to be called, for example, by a message.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question