Files
SupportBot/commands/links.js
T

34 lines
788 B
JavaScript
Raw Normal View History

2019-06-09 23:52:41 +01:00
// SupportBot
// Command: Help
2019-06-18 13:09:00 -03:00
const Discord = require( "discord.js" );
2019-06-09 23:52:41 +01:00
const bot = new Discord.Client()
2019-06-18 13:09:00 -03:00
bot.settings = require( "../settings.json" );
2019-06-09 23:52:41 +01:00
2019-06-18 13:09:00 -03:00
exports.run = ( bot, message, args ) => {
2019-06-09 23:52:41 +01:00
message.delete();
2019-06-18 13:09:00 -03:00
let botLinks = bot.settings.LINKS;
2019-06-09 23:52:41 +01:00
2019-06-18 13:09:00 -03:00
let links = '';
2019-06-09 23:52:41 +01:00
2019-06-18 13:09:00 -03:00
for ( let name in botLinks ) {
links += `[${name}](${botLinks[ name ]})\n`;
}
let embed = new Discord.RichEmbed()
.setTitle( bot.settings.LINKS_TITLE )
.setDescription( links )
.setColor( bot.settings.colour )
.setFooter( bot.settings.footer )
message.channel.send( embed );
console.log( `\x1b[36m`, `${message.author} has executed ${bot.settings.prefix}${bot.settings.Link_Command}` )
2019-06-09 23:52:41 +01:00
}
exports.help = {
name: bot.settings.Link_Command,
}