Credit Command

This commit is contained in:
Daniel Odendahl Jr
2019-04-14 00:03:38 +00:00
parent c8f74fddf7
commit 45c8d62dd5
189 changed files with 1314 additions and 39 deletions
+7 -1
View File
@@ -12,7 +12,13 @@ module.exports = class ChangelogCommand extends Command {
group: 'util',
memberName: 'changelog',
description: 'Responds with the bot\'s latest 10 commits.',
guarded: true
guarded: true,
credit: [
{
name: 'GitHub API',
url: 'https://developer.github.com/v3/'
}
]
});
}
+29
View File
@@ -0,0 +1,29 @@
const Command = require('../../structures/Command');
const { MessageEmbed } = require('discord.js');
module.exports = class CreditCommand extends Command {
constructor(client) {
super(client, {
name: 'credit',
group: 'util',
memberName: 'credit',
description: 'Responds with a command\'s credits list.',
guarded: true,
args: [
{
key: 'command',
prompt: 'Which command would you like to view the credits list of?',
type: 'command'
}
]
});
}
run(msg, { command }) {
const embed = new MessageEmbed()
.setTitle(command.name)
.setColor(0x7289DA)
.setDescription(command.credit.map(credit => `[${credit.name}](${credit.url})`).join('\n'));
return msg.embed(embed);
}
};
+11 -1
View File
@@ -9,7 +9,17 @@ module.exports = class DonateCommand extends Command {
group: 'util',
memberName: 'donate',
description: 'Responds with the bot\'s donation links.',
guarded: true
guarded: true,
credit: [
{
name: 'Patreon',
url: 'https://www.patreon.com/'
},
{
name: 'PayPal',
url: 'https://www.paypal.com/us/home'
}
]
});
}