const { Client, RichEmbed } = require('discord.js');
const client = new Client();
const { Command } = require('discord.js-commando');
module.exports = class avatarCommand extends Command {
constructor(client) {
super(client, {
name: 'avatar',
memberName: 'avatar',
group: 'other',
description: '',
args: [
{
key: 'text',
prompt: 'Какого пользователя?',
type: 'string'
}
]
});
}
run(msg, { user }) {
let embed = new RichEmbed()
.setTitle(`${user.tag}!`)
.setURL(user.displayAvatarURL)
.setImage(user.displayAvatarURL)
.setColor("RANDOM")
msg.embed(embed)
}
}
module.exports = {
name: 'avatar',
description: 'аыфы',
execute(message, user) {
const embed = new Discord.RichEmbed()
.setColor(3447003)
.setImage(`${user.displayAvatarURL}`)
.setThumbnail(`${user.displayAvatarURL}`)
.addField(`${user.username}'s avatar:`, `${user.displayAvatarURL}`, true);
message.channel.send(embed2);
},
};