Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const BaseCommand = require('../../utils/structures/BaseCommand');
- const Discord = require('discord.js');
- module.exports = class SayCommand extends BaseCommand {
- constructor() {
- super('say', 'fun', []);
- }
- async run(client, message, args) {
- const messageToSay = args.join(" ");
- const sayEmbed = Discord.MessageEmbed()
- .setTitle(`${message.author.tag} says: ${messageToSay}`)
- .setFooter(message.author.tag, message.author.displayAvatarURL())
- .setColor("#009900")
- .setTimestamp()
- try {
- await message.channel.send(sayEmbed);
- }catch (err){
- console.log("There was an error while running the say command");
- console.log("Error below");
- console.log(err)
- message.channel.send('I am not able to say that message.')
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement