summaryrefslogtreecommitdiff
path: root/src/commands/fun/8ball.js
blob: 6be4f01f943d4f700e8af003d6dd360164fcf79e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
const { Command } = require('discord.js-commando');
const { MessageEmbed } = require('discord.js');

module.exports = class EightBallFun extends Command {
	constructor(client) {
		super(client, {
            name: '8ball',
            aliases: [
				'8b',
				'9b',
				'9ball',
				'7b',
				'7ball'
			],
			group: 'fun',
			memberName: '8ball',
			description: 'Shake the 8ball for a fortune.',
			throttling: {
				usages: 5,
				duration: 30
			},
			examples: ['uwu!8ball', 'uwu!8b'],
			userPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY'],
			clientPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY']
		});
	}
	run(msg) {
		var r = ['Yes~ uwu', 'No.', 'Yes!', 'No!', 'What, no.', 'Yes.', 'Maybe.', 'Perhaps.', 'Try again.', 'I\'m not sure.'];
		var s = r[Math.floor(Math.random() * r.length)];

		let embed = new MessageEmbed()

		    .setAuthor('The 8-ball says', 'https://upload.wikimedia.org/wikipedia/commons/thumb/f/fd/8-Ball_Pool.svg/500px-8-Ball_Pool.svg.png')
		    .setDescription('`' + s + '`');

		msg.channel.send(embed);
	}
};