This commit is contained in:
zakt0210
2017-12-06 13:36:26 -05:00
parent 539425ba81
commit 604c71c02e
2 changed files with 121 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
const { Command } = require('discord.js-commando');
const fruits = require('../../assets/json/fruit');
module.exports = class FruitCommand extends Command {
constructor(client) {
super(client, {
name: 'fruit',
group: 'random',
memberName: 'fruit',
description: 'Responds with a random fruit.'
});
}
run(msg) {
return msg.say(fruits[Math.floor(Math.random() * fruits.length)]);
}
};