aboutsummaryrefslogtreecommitdiff
path: root/src/commands/fun/eightBall.ts
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-07-14 21:22:09 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2021-07-14 21:22:09 -0400
commit53d2b18f7f73d5696fb7cd86d1c164a790dfdcc3 (patch)
treef95f23aad382879b35860d4d3be3642068fac8a2 /src/commands/fun/eightBall.ts
parenteaaae08aeee1fa16a4e1ad0b26fceb42885bfcde (diff)
downloadtanzanite-53d2b18f7f73d5696fb7cd86d1c164a790dfdcc3.tar.gz
tanzanite-53d2b18f7f73d5696fb7cd86d1c164a790dfdcc3.tar.bz2
tanzanite-53d2b18f7f73d5696fb7cd86d1c164a790dfdcc3.zip
started moving over some other commands
Diffstat (limited to 'src/commands/fun/eightBall.ts')
-rw-r--r--src/commands/fun/eightBall.ts64
1 files changed, 64 insertions, 0 deletions
diff --git a/src/commands/fun/eightBall.ts b/src/commands/fun/eightBall.ts
new file mode 100644
index 0000000..7b7d39c
--- /dev/null
+++ b/src/commands/fun/eightBall.ts
@@ -0,0 +1,64 @@
+import { BushCommand, BushMessage, BushSlashMessage } from '../../lib';
+
+export default class EightBallCommand extends BushCommand {
+ public constructor() {
+ super('eightBall', {
+ aliases: ['8ball', 'eightball'],
+ category: 'fun',
+ description: {
+ content: 'Ask questions for a randomly generated response.',
+ usage: '8Ball <question>',
+ examples: ['8Ball does anyone love me?']
+ },
+ args: [
+ {
+ id: 'question',
+ type: 'string',
+ match: 'rest',
+ prompt: {
+ start: 'What question would you like answered?',
+ retry: '{error} Invalid question.'
+ }
+ }
+ ],
+ slash: true,
+ slashOptions: [
+ {
+ name: 'question',
+ description: 'What question would you like answered?',
+ type: 'STRING',
+ required: true
+ }
+ ],
+ clientPermissions: ['SEND_MESSAGES'],
+ userPermissions: ['SEND_MESSAGES']
+ });
+ }
+
+ public async exec(message: BushMessage | BushSlashMessage): Promise<void> {
+ const responses = [
+ 'It is certain',
+ 'Without a doubt',
+ 'You may rely on it',
+ 'Yes definitely',
+ 'It is decidedly so',
+ 'As I see it, yes',
+ 'Most likely',
+ 'Yes',
+ 'Outlook good',
+ 'Signs point to yes',
+ 'Reply hazy try again',
+ 'Better not tell you now',
+ 'Ask again later',
+ 'Cannot predict now',
+ 'Concentrate and ask again',
+ "Don't count on it",
+ 'Outlook not so good',
+ 'My sources say no',
+ 'Very doubtful',
+ 'My reply is no'
+ ];
+ const answer = responses[Math.floor(Math.random() * responses.length)];
+ await message.util.reply(answer);
+ }
+}