From 785d75743d4666f312d15da03de54eda57baad5e Mon Sep 17 00:00:00 2001 From: 8cy <50817549+8cy@users.noreply.github.com> Date: Sat, 9 May 2020 16:33:22 -0700 Subject: add google, suggest + add suggest to joinmsg - account for missing version increments --- src/commands/utility/google.ts | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 src/commands/utility/google.ts (limited to 'src/commands/utility/google.ts') diff --git a/src/commands/utility/google.ts b/src/commands/utility/google.ts new file mode 100644 index 0000000..68185cc --- /dev/null +++ b/src/commands/utility/google.ts @@ -0,0 +1,35 @@ +import { Command, CommandoMessage } from 'discord.js-commando'; +import emoji from 'emoji-random'; +import { MessageEmbed } from 'discord.js'; + +module.exports = class GoogleUtility extends Command { + constructor(client) { + super(client, { + name: 'google', + group: 'utility', + memberName: 'google', + description: 'Googles something for you.', + examples: ['uwu!google sin'], + userPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY'], + clientPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY'], + throttling: { + usages: 5, + duration: 30 + }, + args: [ + { + key: 'gTerm', + prompt: 'What would you like to search for?', + type: 'string' + } + ] + }); + } + async run(msg: CommandoMessage, { gTerm }) { + let embed = new MessageEmbed() + .setTitle('**Google Search**') + .setColor(0xFFCC4D) + .addField('Searching Google for`' + gTerm + '`...', `[Click Here](https://google.com/search?q=${gTerm.replace(/ /g, '%20')})`) + msg.say(embed) + } +}; \ No newline at end of file -- cgit v1.2.3