From e512c52e0f69aa47aa6872eba37f5ac6bdeae333 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Fri, 19 Mar 2021 17:23:07 -0400 Subject: [PATCH] Bottom Text Command --- commands/edit-meme/bottom-text.js | 44 +++++++++++++++++++++++++++++++ package.json | 8 +++--- 2 files changed, 48 insertions(+), 4 deletions(-) create mode 100644 commands/edit-meme/bottom-text.js diff --git a/commands/edit-meme/bottom-text.js b/commands/edit-meme/bottom-text.js new file mode 100644 index 00000000..b730e437 --- /dev/null +++ b/commands/edit-meme/bottom-text.js @@ -0,0 +1,44 @@ +const Command = require('../../structures/Command'); + +module.exports = class BottomTextCommand extends Command { + constructor(client) { + super(client, { + name: 'bottom-text', + group: 'edit-meme', + memberName: 'bottom-text', + description: 'Sends a bottom text meme.', + throttling: { + usages: 1, + duration: 10 + }, + clientPermissions: ['ATTACH_FILES'], + credit: [ + { + name: 'ShareFonts.net', + url: 'https://www.wfonts.com/', + reason: 'Impact Font', + reasonURL: 'https://www.wfonts.com/font/impact' + } + ], + args: [ + { + key: 'top', + prompt: 'What should the top row of the meme to be?', + type: 'string', + max: 50, + parse: top => top.toUpperCase() + }, + { + key: 'image', + prompt: 'What image would you like to edit?', + type: 'image-or-avatar', + default: msg => msg.author.displayAvatarURL({ format: 'png', size: 2048 }) + } + ] + }); + } + + run(msg, { top, image }) { + return this.client.registry.commands.get('meme-gen-classic').run(msg, { top, bottom: 'BOTTOM TEXT', image }); + } +}; diff --git a/package.json b/package.json index c9967b8d..894f4d37 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiao", - "version": "132.8.0", + "version": "132.9.0", "description": "Your personal server companion.", "main": "Xiao.js", "scripts": { @@ -32,7 +32,7 @@ }, "dependencies": { "@discordjs/collection": "^0.1.6", - "@discordjs/opus": "^0.4.0", + "@discordjs/opus": "^0.5.0", "@vitalets/google-translate-api": "^5.1.0", "aki-api": "^5.2.1", "bombsweeper.js": "^1.0.1", @@ -54,7 +54,7 @@ "font-finder": "^1.1.0", "gifencoder": "^2.0.1", "gm": "^1.23.1", - "html-entities": "^2.1.0", + "html-entities": "^2.1.1", "ioredis": "^4.24.2", "js-beautify": "^1.13.5", "js-chess-engine": "^0.10.0", @@ -74,7 +74,7 @@ "tesseract.js": "^2.1.4", "text-diff": "^1.0.1", "tictactoe-minimax-ai": "^1.2.1", - "user-agents": "^1.0.594", + "user-agents": "^1.0.595", "valid-url": "^1.0.9", "winston": "^3.3.3", "ytdl-core": "^4.5.0"