From c484753ee15dbe2a5ce9c6297f22fabb52ce3b7e Mon Sep 17 00:00:00 2001 From: Unknown Date: Sat, 24 Feb 2018 14:59:35 -0500 Subject: New Command system --- commands/Owners Only/poweroff.js | 20 ++++++++++++++++++++ commands/Owners Only/say.js | 20 ++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 commands/Owners Only/poweroff.js create mode 100644 commands/Owners Only/say.js (limited to 'commands/Owners Only') diff --git a/commands/Owners Only/poweroff.js b/commands/Owners Only/poweroff.js new file mode 100644 index 0000000..ddd0c56 --- /dev/null +++ b/commands/Owners Only/poweroff.js @@ -0,0 +1,20 @@ +exports.run = async (bot, msg) => { + if (!['242775871059001344', '247221105515823104', '236279900728721409'].includes(msg.author.id)) { + msg.reply('Nope! You need the person who created this bot to use this command.'); + } + else { + await msg.reply(':warning: Pokebot is now powering off!'); + console.log('Pokebot is now powering off...'); + process.exit(0); + } +}; + +exports.conf = { + aliases: ['reboot', 'restart'], + guildOnly: true, +}; + +exports.help = { + name: 'poweroff', + description: 'Powers off the bot.', +}; diff --git a/commands/Owners Only/say.js b/commands/Owners Only/say.js new file mode 100644 index 0000000..0f8a6df --- /dev/null +++ b/commands/Owners Only/say.js @@ -0,0 +1,20 @@ +exports.run = async (bot, msg, args) => { + if (!['242775871059001344', '247221105515823104', '236279900728721409'].includes(msg.author.id)) { + msg.reply('Nope! You need the person who created this bot to use this command.'); + } + else { + msg.channel.send(args.join(' ')); + msg.delete(); + } +}; + +exports.conf = { + aliases: [], + guildOnly: true, +}; + +exports.help = { + name: 'say', + description: 'Control on what the bot says.', + usage: '<...text>', +}; -- cgit v1.2.3