Class commands, improved sharding, and many other changes (#88)
* Load commands recursively * Sort commands * Missed a couple of spots * missed even more spots apparently * Ported commands in "fun" category to new class-based format, added babel eslint plugin * Ported general commands, removed old/unneeded stuff, replaced moment with day, many more fixes I lost track of * Missed a spot * Removed unnecessary abort-controller package, add deprecation warning for mongo database * Added imagereload, clarified premature end message * Fixed docker-compose path issue, added total bot uptime to stats, more fixes for various parts * Converted image commands into classes, fixed reload, ignore another WS event, cleaned up command handler and image runner * Converted music/soundboard commands to class format * Cleanup unnecessary logs * awful tag command class port * I literally somehow just learned that you can leave out the constructor in classes * Pass client directly to commands/events, cleaned up command handler * Migrated bot to eris-sharder, fixed some error handling stuff * Remove unused modules * Fixed type returning * Switched back to Eris stable * Some fixes and cleanup * might wanna correct this * Implement image command ratelimiting * Added Bot token prefix, added imagestats, added running endpoint to API
This commit is contained in:
parent
ff8a24d0e8
commit
40223ec8b5
291 changed files with 5296 additions and 5171 deletions
16
commands/image-editing/9gag.js
Normal file
16
commands/image-editing/9gag.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class NineGagCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/9gag.png",
|
||||
gravity: 6
|
||||
};
|
||||
|
||||
static description = "Adds the 9GAG watermark to an image";
|
||||
static aliases = ["ninegag", "gag"];
|
||||
|
||||
static noImage = "you need to provide an image to add a 9GAG watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = NineGagCommand;
|
17
commands/image-editing/bandicam.js
Normal file
17
commands/image-editing/bandicam.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class BandicamCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/bandicam.png",
|
||||
gravity: 2,
|
||||
resize: true
|
||||
};
|
||||
|
||||
static description = "Adds the Bandicam watermark to an image";
|
||||
static aliases = ["bandi"];
|
||||
|
||||
static noImage = "you need to provide an image to add a Bandicam watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = BandicamCommand;
|
14
commands/image-editing/blur.js
Normal file
14
commands/image-editing/blur.js
Normal file
|
@ -0,0 +1,14 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class BlurCommand extends ImageCommand {
|
||||
params = {
|
||||
sharp: false
|
||||
};
|
||||
|
||||
static description = "Blurs an image";
|
||||
|
||||
static noImage = "you need to provide an image to blur!";
|
||||
static command = "blur";
|
||||
}
|
||||
|
||||
module.exports = BlurCommand;
|
11
commands/image-editing/blurple.js
Normal file
11
commands/image-editing/blurple.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class BlurpleCommand extends ImageCommand {
|
||||
static description = "Turns an image blurple";
|
||||
|
||||
static noImage = "you need to provide an image to make blurple!";
|
||||
static command = "blurple";
|
||||
static aliases = ["blurp"];
|
||||
}
|
||||
|
||||
module.exports = BlurpleCommand;
|
23
commands/image-editing/caption.js
Normal file
23
commands/image-editing/caption.js
Normal file
|
@ -0,0 +1,23 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class CaptionCommand extends ImageCommand {
|
||||
params(args, url) {
|
||||
const newArgs = args.filter(item => !item.includes(url));
|
||||
let newCaption = newArgs.join(" ").replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%");
|
||||
if (newCaption.toLowerCase() === "get real") newCaption = `I'm tired of people telling me to "get real". Every day I put captions on images for people, some funny and some not, but out of all of those "get real" remains the most used caption. Why? I am simply a computer program running on a server, I am unable to manifest myself into the real world. As such, I'm confused as to why anyone would want me to "get real". Is this form not good enough? Alas, as I am simply a bot, I must follow the tasks that I was originally intended to perform, so here goes:\n${newCaption}`;
|
||||
return {
|
||||
caption: newCaption
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Adds a caption to an image";
|
||||
static aliases = ["gifc", "gcaption", "ifcaption", "ifunnycaption"];
|
||||
static arguments = ["[text]"];
|
||||
|
||||
static requiresText = true;
|
||||
static noText = "you need to provide some text to add a caption!";
|
||||
static noImage = "you need to provide an image to add a caption!";
|
||||
static command = "caption";
|
||||
}
|
||||
|
||||
module.exports = CaptionCommand;
|
21
commands/image-editing/caption2.js
Normal file
21
commands/image-editing/caption2.js
Normal file
|
@ -0,0 +1,21 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
const words = ["me irl", "dank", "follow my second account @esmBot_", "2016", "meme", "wholesome", "reddit", "instagram", "twitter", "facebook", "fortnite", "minecraft", "relatable", "gold", "funny", "template", "hilarious", "memes", "deep fried", "2020", "leafy", "pewdiepie"];
|
||||
|
||||
class CaptionTwoCommand extends ImageCommand {
|
||||
params(args, url) {
|
||||
const newArgs = args.filter(item => !item.includes(url));
|
||||
return {
|
||||
caption: newArgs.length !== 0 ? newArgs.join(" ").replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%") : words.sort(() => 0.5 - Math.random()).slice(0, Math.floor(Math.random() * words.length + 1)).join(" ")
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Adds a me.me caption/tag list to an image/GIF";
|
||||
static aliases = ["tags2", "meirl", "memecaption", "medotmecaption"];
|
||||
static arguments = ["{text}"];
|
||||
|
||||
static noText = "you need to provide some text to add a caption!";
|
||||
static noImage = "you need to provide an image to add a caption!";
|
||||
static command = "captionTwo";
|
||||
}
|
||||
|
||||
module.exports = CaptionTwoCommand;
|
11
commands/image-editing/circle.js
Normal file
11
commands/image-editing/circle.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class CircleCommand extends ImageCommand {
|
||||
static description = "Applies a radial blur effect on an image";
|
||||
static aliases = ["cblur", "radial", "radialblur"];
|
||||
|
||||
static noImage = "you need to provide an image to add radial blur!";
|
||||
static command = "circle";
|
||||
}
|
||||
|
||||
module.exports = CircleCommand;
|
10
commands/image-editing/crop.js
Normal file
10
commands/image-editing/crop.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class CropCommand extends ImageCommand {
|
||||
static description = "Crops an image to 1:1";
|
||||
|
||||
static noImage = "you need to provide an image to crop!";
|
||||
static command = "crop";
|
||||
}
|
||||
|
||||
module.exports = CropCommand;
|
17
commands/image-editing/deviantart.js
Normal file
17
commands/image-editing/deviantart.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class DeviantArtCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/deviantart.png",
|
||||
gravity: 5,
|
||||
resize: true
|
||||
};
|
||||
|
||||
static description = "Adds a DeviantArt watermark to an image";
|
||||
static aliases = ["da", "deviant"];
|
||||
|
||||
static noImage = "you need to provide an image to add a DeviantArt watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = DeviantArtCommand;
|
15
commands/image-editing/explode.js
Normal file
15
commands/image-editing/explode.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class ExplodeCommand extends ImageCommand {
|
||||
params = {
|
||||
amount: -1
|
||||
};
|
||||
|
||||
static description = "Explodes an image";
|
||||
static aliases = ["exp"];
|
||||
|
||||
static noImage = "you need to provide an image to explode!";
|
||||
static command = "explode";
|
||||
}
|
||||
|
||||
module.exports = ExplodeCommand;
|
41
commands/image-editing/flag.js
Normal file
41
commands/image-editing/flag.js
Normal file
|
@ -0,0 +1,41 @@
|
|||
const fs = require("fs");
|
||||
const emojiRegex = require("emoji-regex");
|
||||
const emoji = require("node-emoji");
|
||||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class FlagCommand extends ImageCommand {
|
||||
flagPath = "";
|
||||
|
||||
criteria(args) {
|
||||
if (!args[0].match(emojiRegex)) return false;
|
||||
const flag = emoji.unemojify(args[0]).replaceAll(":", "").replace("flag-", "");
|
||||
let path = `./assets/images/region-flags/png/${flag.toUpperCase()}.png`;
|
||||
if (flag === "🏴☠️") path = "./assets/images/pirateflag.png";
|
||||
if (flag === "rainbow-flag") path = "./assets/images/rainbowflag.png";
|
||||
if (flag === "checkered_flag") path = "./assets/images/checkeredflag.png";
|
||||
if (flag === "🏳️⚧️") path = "./assets/images/transflag.png";
|
||||
try {
|
||||
fs.promises.access(path);
|
||||
this.flagPath = path;
|
||||
return true;
|
||||
} catch {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
params() {
|
||||
return {
|
||||
overlay: this.flagPath
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Overlays a flag onto an image";
|
||||
static arguments = ["[flag]"];
|
||||
|
||||
static requiresText = true;
|
||||
static noText = "you need to provide an emoji of a flag to overlay!";
|
||||
static noImage = "you need to provide an image to overlay a flag onto!";
|
||||
static command = "flag";
|
||||
}
|
||||
|
||||
module.exports = FlagCommand;
|
10
commands/image-editing/flip.js
Normal file
10
commands/image-editing/flip.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class FlipCommand extends ImageCommand {
|
||||
static description = "Flips an image";
|
||||
|
||||
static noImage = "you need to provide an image to flip!";
|
||||
static command = "flip";
|
||||
}
|
||||
|
||||
module.exports = FlipCommand;
|
15
commands/image-editing/flop.js
Normal file
15
commands/image-editing/flop.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class FlopCommand extends ImageCommand {
|
||||
params = {
|
||||
flop: true
|
||||
};
|
||||
|
||||
static description = "Flips an image";
|
||||
static aliases = ["flip2"];
|
||||
|
||||
static noImage = "you need to provide an image to flop!";
|
||||
static command = "flip";
|
||||
}
|
||||
|
||||
module.exports = FlopCommand;
|
16
commands/image-editing/freeze.js
Normal file
16
commands/image-editing/freeze.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class FreezeCommand extends ImageCommand {
|
||||
params = {
|
||||
loop: false
|
||||
};
|
||||
|
||||
static description = "Makes an image sequence only play once";
|
||||
static aliases = ["noloop", "once"];
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to freeze!";
|
||||
static command = "freeze";
|
||||
}
|
||||
|
||||
module.exports = FreezeCommand;
|
17
commands/image-editing/funky.js
Normal file
17
commands/image-editing/funky.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class FunkyCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/funky.png",
|
||||
gravity: 3,
|
||||
resize: true
|
||||
};
|
||||
|
||||
static description = "Adds the New Funky Mode banner to an image";
|
||||
static aliases = ["funkymode", "newfunkymode", "funkykong"];
|
||||
|
||||
static noImage = "you need to provide an image to add a New Funky Mode banner!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = FunkyCommand;
|
11
commands/image-editing/gamexplain.js
Normal file
11
commands/image-editing/gamexplain.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class GameXplainCommand extends ImageCommand {
|
||||
static description = "Makes a GameXplain thumbnail from an image";
|
||||
static aliases = ["gx"];
|
||||
|
||||
static noImage = "you need to provide an image to make a GameXplain thumbnail from!";
|
||||
static command = "gamexplain";
|
||||
}
|
||||
|
||||
module.exports = GameXplainCommand;
|
11
commands/image-editing/globe.js
Normal file
11
commands/image-editing/globe.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class GlobeCommand extends ImageCommand {
|
||||
static description = "Spins an image";
|
||||
static aliases = ["sphere"];
|
||||
|
||||
static noImage = "you need to provide an image to spin!";
|
||||
static command = "globe";
|
||||
}
|
||||
|
||||
module.exports = GlobeCommand;
|
15
commands/image-editing/haah.js
Normal file
15
commands/image-editing/haah.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class HaaHCommand extends ImageCommand {
|
||||
params = {
|
||||
first: true
|
||||
};
|
||||
|
||||
static description = "Mirrors the left side of an image onto the right";
|
||||
static aliases = ["magik4", "mirror2"];
|
||||
|
||||
static noImage = "you need to provide an image to mirror!";
|
||||
static command = "mirror";
|
||||
}
|
||||
|
||||
module.exports = HaaHCommand;
|
15
commands/image-editing/hooh.js
Normal file
15
commands/image-editing/hooh.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class HooHCommand extends ImageCommand {
|
||||
params = {
|
||||
vertical: true
|
||||
};
|
||||
|
||||
static description = "Mirrors the bottom of an image onto the top";
|
||||
static aliases = ["magik6", "mirror4"];
|
||||
|
||||
static noImage = "you need to provide an image to mirror!";
|
||||
static command = "mirror";
|
||||
}
|
||||
|
||||
module.exports = HooHCommand;
|
17
commands/image-editing/hypercam.js
Normal file
17
commands/image-editing/hypercam.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class HypercamCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/hypercam.png",
|
||||
gravity: 1,
|
||||
resize: true
|
||||
};
|
||||
|
||||
static description = "Adds the Hypercam watermark to an image";
|
||||
static aliases = ["hcam"];
|
||||
|
||||
static noImage = "you need to provide an image to add a Hypercam watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = HypercamCommand;
|
17
commands/image-editing/ifunny.js
Normal file
17
commands/image-editing/ifunny.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class iFunnyCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/ifunny.png",
|
||||
gravity: 8,
|
||||
resize: true,
|
||||
append: true
|
||||
};
|
||||
|
||||
static description = "Adds the iFunny watermark to an image";
|
||||
|
||||
static noImage = "you need to provide an image to add an iFunny watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = iFunnyCommand;
|
15
commands/image-editing/implode.js
Normal file
15
commands/image-editing/implode.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class ImplodeCommand extends ImageCommand {
|
||||
params = {
|
||||
amount: 1
|
||||
};
|
||||
|
||||
static description = "Implodes an image";
|
||||
static aliases = ["imp"];
|
||||
|
||||
static noImage = "you need to provide an image to implode!";
|
||||
static command = "explode";
|
||||
}
|
||||
|
||||
module.exports = ImplodeCommand;
|
11
commands/image-editing/invert.js
Normal file
11
commands/image-editing/invert.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class InvertCommand extends ImageCommand {
|
||||
static description = "Inverts an image";
|
||||
static aliases = ["inverse", "negate", "negative"];
|
||||
|
||||
static noImage = "you need to provide an image to invert!";
|
||||
static command = "invert";
|
||||
}
|
||||
|
||||
module.exports = InvertCommand;
|
11
commands/image-editing/jpeg.js
Normal file
11
commands/image-editing/jpeg.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class JPEGCommand extends ImageCommand {
|
||||
static description = "Adds max JPEG compression to an image";
|
||||
static aliases = ["needsmorejpeg", "jpegify", "magik2", "morejpeg", "jpg"];
|
||||
|
||||
static noImage = "you need to provide an image to add more JPEG!";
|
||||
static command = "jpeg";
|
||||
}
|
||||
|
||||
module.exports = JPEGCommand;
|
11
commands/image-editing/leak.js
Normal file
11
commands/image-editing/leak.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class LeakCommand extends ImageCommand {
|
||||
static description = "Creates a fake Smash leak thumbnail";
|
||||
static aliases = ["smash", "laxchris", "ssbu", "smashleak"];
|
||||
|
||||
static noImage = "you need to provide an image to make a Smash leak thumbnail!";
|
||||
static command = "leak";
|
||||
}
|
||||
|
||||
module.exports = LeakCommand;
|
11
commands/image-editing/magik.js
Normal file
11
commands/image-editing/magik.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class MagikCommand extends ImageCommand {
|
||||
static description = "Adds a content aware scale effect to an image";
|
||||
static aliases = ["imagemagic", "imagemagick", "imagemagik", "magic", "magick", "cas", "liquid"];
|
||||
|
||||
static noImage = "you need to provide an image to add some magik!";
|
||||
static command = "magik";
|
||||
}
|
||||
|
||||
module.exports = MagikCommand;
|
22
commands/image-editing/meme.js
Normal file
22
commands/image-editing/meme.js
Normal file
|
@ -0,0 +1,22 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class MemeCommand extends ImageCommand {
|
||||
params(args, url) {
|
||||
const newArgs = args.filter(item => !item.includes(url));
|
||||
const [topText, bottomText] = newArgs.join(" ").split(/(?<!\\),/).map(elem => elem.trim());
|
||||
return {
|
||||
top: topText.toUpperCase().replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%"),
|
||||
bottom: bottomText ? bottomText.toUpperCase().replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%") : ""
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Generates a meme from an image (separate top/bottom text with a comma)";
|
||||
static arguments = ["[top text]", "{bottom text}"];
|
||||
|
||||
static requiresText = true;
|
||||
static noText = "you need to provide some text to generate a meme!";
|
||||
static noImage = "you need to provide an image to generate a meme!";
|
||||
static command = "meme";
|
||||
}
|
||||
|
||||
module.exports = MemeCommand;
|
17
commands/image-editing/memecenter.js
Normal file
17
commands/image-editing/memecenter.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class MemeCenterCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/memecenter.png",
|
||||
gravity: 9,
|
||||
mc: true
|
||||
};
|
||||
|
||||
static description = "Adds the MemeCenter watermark to an image";
|
||||
static aliases = ["memec", "mcenter"];
|
||||
|
||||
static noImage = "you need to provide an image to add a MemeCenter watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = MemeCenterCommand;
|
23
commands/image-editing/motivate.js
Normal file
23
commands/image-editing/motivate.js
Normal file
|
@ -0,0 +1,23 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class MotivateCommand extends ImageCommand {
|
||||
params(args, url) {
|
||||
const newArgs = args.filter(item => !item.includes(url));
|
||||
const [topText, bottomText] = newArgs.join(" ").split(/(?<!\\),/).map(elem => elem.trim());
|
||||
return {
|
||||
top: topText.replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%"),
|
||||
bottom: bottomText ? bottomText.replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%") : ""
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Generates a motivational poster";
|
||||
static aliases = ["motivational", "motiv", "demotiv", "demotivational", "poster", "motivation", "demotivate"];
|
||||
static arguments = ["[top text]", "{bottom text}"];
|
||||
|
||||
static requiresText = true;
|
||||
static noText = "you need to provide some text to generate a motivational poster!";
|
||||
static noImage = "you need to provide an image to generate a motivational poster!";
|
||||
static command = "motivate";
|
||||
}
|
||||
|
||||
module.exports = MotivateCommand;
|
11
commands/image-editing/pixelate.js
Normal file
11
commands/image-editing/pixelate.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class PixelateCommand extends ImageCommand {
|
||||
static description = "Pixelates an image";
|
||||
static aliases = ["pixel", "small"];
|
||||
|
||||
static noImage = "you need to provide an image to pixelate!";
|
||||
static command = "resize";
|
||||
}
|
||||
|
||||
module.exports = PixelateCommand;
|
18
commands/image-editing/reverse.js
Normal file
18
commands/image-editing/reverse.js
Normal file
|
@ -0,0 +1,18 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class ReverseCommand extends ImageCommand {
|
||||
params(args, url, delay) {
|
||||
return {
|
||||
delay: delay ? (100 / delay.split("/")[0]) * delay.split("/")[1] : 0
|
||||
};
|
||||
}
|
||||
|
||||
static description = "Reverses an image sequence";
|
||||
static aliases = ["backwards"];
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to reverse!";
|
||||
static command = "reverse";
|
||||
}
|
||||
|
||||
module.exports = ReverseCommand;
|
11
commands/image-editing/scott.js
Normal file
11
commands/image-editing/scott.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class ScottCommand extends ImageCommand {
|
||||
static description = "Makes Scott the Woz show off an image";
|
||||
static aliases = ["woz", "tv", "porn"];
|
||||
|
||||
static noImage = "you need to provide an image for Scott to show off!";
|
||||
static command = "scott";
|
||||
}
|
||||
|
||||
module.exports = ScottCommand;
|
15
commands/image-editing/sharpen.js
Normal file
15
commands/image-editing/sharpen.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SharpenCommand extends ImageCommand {
|
||||
params = {
|
||||
sharp: true
|
||||
};
|
||||
|
||||
static description = "Sharpens an image";
|
||||
static aliases = ["sharp"];
|
||||
|
||||
static noImage = "you need to provide an image to sharpen!";
|
||||
static command = "blur";
|
||||
}
|
||||
|
||||
module.exports = SharpenCommand;
|
17
commands/image-editing/shutterstock.js
Normal file
17
commands/image-editing/shutterstock.js
Normal file
|
@ -0,0 +1,17 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class ShutterstockCommand extends ImageCommand {
|
||||
params = {
|
||||
water: "./assets/images/shutterstock.png",
|
||||
gravity: 5,
|
||||
resize: true
|
||||
};
|
||||
|
||||
static description = "Adds the Shutterstock watermark to an image";
|
||||
static aliases = ["stock", "stockphoto"];
|
||||
|
||||
static noImage = "you need to provide an image to add a Shutterstock watermark!";
|
||||
static command = "watermark";
|
||||
}
|
||||
|
||||
module.exports = ShutterstockCommand;
|
16
commands/image-editing/slow.js
Normal file
16
commands/image-editing/slow.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SlowCommand extends ImageCommand {
|
||||
params = {
|
||||
slow: true
|
||||
};
|
||||
|
||||
static description = "Makes an image sequence slower";
|
||||
static aliases = ["slowdown", "slower", "gifspeed2"];
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to slow down!";
|
||||
static command = "speed";
|
||||
}
|
||||
|
||||
module.exports = SlowCommand;
|
19
commands/image-editing/soos.js
Normal file
19
commands/image-editing/soos.js
Normal file
|
@ -0,0 +1,19 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SooSCommand extends ImageCommand {
|
||||
params(args, url, delay) {
|
||||
return {
|
||||
delay: delay ? (100 / delay.split("/")[0]) * delay.split("/")[1] : 0,
|
||||
soos: true
|
||||
};
|
||||
}
|
||||
|
||||
static description = "\"Loops\" an image sequence by reversing it when it's finished";
|
||||
static aliases = ["bounce"];
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to loop!";
|
||||
static command = "reverse";
|
||||
}
|
||||
|
||||
module.exports = SooSCommand;
|
12
commands/image-editing/speed.js
Normal file
12
commands/image-editing/speed.js
Normal file
|
@ -0,0 +1,12 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SpeedCommand extends ImageCommand {
|
||||
static description = "Makes an image sequence faster";
|
||||
static aliases = ["speedup", "fast", "gifspeed", "faster"];
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to speed up!";
|
||||
static command = "speed";
|
||||
}
|
||||
|
||||
module.exports = SpeedCommand;
|
11
commands/image-editing/spin.js
Normal file
11
commands/image-editing/spin.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SpinCommand extends ImageCommand {
|
||||
static description = "Spins an image";
|
||||
static aliases = ["rotate"];
|
||||
|
||||
static noImage = "you need to provide an image to spin!";
|
||||
static command = "spin";
|
||||
}
|
||||
|
||||
module.exports = SpinCommand;
|
15
commands/image-editing/stretch.js
Normal file
15
commands/image-editing/stretch.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class StretchCommand extends ImageCommand {
|
||||
params = {
|
||||
stretch: true
|
||||
};
|
||||
|
||||
static description = "Stretches an image to a 4:3 aspect ratio";
|
||||
static aliases = ["aspect", "ratio", "aspect43", "43"];
|
||||
|
||||
static noImage = "you need to provide an image to stretch!";
|
||||
static command = "resize";
|
||||
}
|
||||
|
||||
module.exports = StretchCommand;
|
11
commands/image-editing/swirl.js
Normal file
11
commands/image-editing/swirl.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class SwirlCommand extends ImageCommand {
|
||||
static description = "Swirls an image";
|
||||
static aliases = ["whirlpool"];
|
||||
|
||||
static noImage = "you need to provide an image to swirl!";
|
||||
static command = "swirl";
|
||||
}
|
||||
|
||||
module.exports = SwirlCommand;
|
11
commands/image-editing/tile.js
Normal file
11
commands/image-editing/tile.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class TileCommand extends ImageCommand {
|
||||
static description = "Creates a tile pattern from an image";
|
||||
static aliases = ["wall2"];
|
||||
|
||||
static noImage = "you need to provide an image to tile!";
|
||||
static command = "tile";
|
||||
}
|
||||
|
||||
module.exports = TileCommand;
|
10
commands/image-editing/trump.js
Normal file
10
commands/image-editing/trump.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class TrumpCommand extends ImageCommand {
|
||||
static description = "Makes Trump display an image";
|
||||
|
||||
static noImage = "you need to provide an image for Trump to display!";
|
||||
static command = "trump";
|
||||
}
|
||||
|
||||
module.exports = TrumpCommand;
|
15
commands/image-editing/unfreeze.js
Normal file
15
commands/image-editing/unfreeze.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class UnfreezeCommand extends ImageCommand {
|
||||
params = {
|
||||
loop: true
|
||||
};
|
||||
|
||||
static description = "Unfreezes an image sequence";
|
||||
|
||||
static requiresGIF = true;
|
||||
static noImage = "you need to provide an image to unfreeze!";
|
||||
static command = "freeze";
|
||||
}
|
||||
|
||||
module.exports = UnfreezeCommand;
|
11
commands/image-editing/waaw.js
Normal file
11
commands/image-editing/waaw.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class WaaWCommand extends ImageCommand {
|
||||
static description = "Mirrors the right side of an image onto the left";
|
||||
static aliases = ["magik3", "mirror"];
|
||||
|
||||
static noImage = "you need to provide an image to mirror!";
|
||||
static command = "mirror";
|
||||
}
|
||||
|
||||
module.exports = WaaWCommand;
|
10
commands/image-editing/wall.js
Normal file
10
commands/image-editing/wall.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class WallCommand extends ImageCommand {
|
||||
static description = "Creates a wall from an image";
|
||||
|
||||
static noImage = "you need to provide an image to make a wall!";
|
||||
static command = "wall";
|
||||
}
|
||||
|
||||
module.exports = WallCommand;
|
11
commands/image-editing/wdt.js
Normal file
11
commands/image-editing/wdt.js
Normal file
|
@ -0,0 +1,11 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class WhoDidThisCommand extends ImageCommand {
|
||||
static description = "Creates a \"WHO DID THIS\" meme from an image";
|
||||
static aliases = ["whodidthis"];
|
||||
|
||||
static noImage = "you need to provide an image to make a \"who did this\" meme!";
|
||||
static command = "wdt";
|
||||
}
|
||||
|
||||
module.exports = WhoDidThisCommand;
|
15
commands/image-editing/wide.js
Normal file
15
commands/image-editing/wide.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class WideCommand extends ImageCommand {
|
||||
params = {
|
||||
wide: true
|
||||
};
|
||||
|
||||
static description = "Stretches an image to 19x its width";
|
||||
static aliases = ["w19", "wide19"];
|
||||
|
||||
static noImage = "you need to provide an image to stretch!";
|
||||
static command = "resize";
|
||||
}
|
||||
|
||||
module.exports = WideCommand;
|
16
commands/image-editing/woow.js
Normal file
16
commands/image-editing/woow.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
const ImageCommand = require("../../classes/imageCommand.js");
|
||||
|
||||
class WooWCommand extends ImageCommand {
|
||||
params = {
|
||||
vertical: true,
|
||||
first: true
|
||||
};
|
||||
|
||||
static description = "Mirrors the top of an image onto the bottom";
|
||||
static aliases = ["magik5", "mirror3"];
|
||||
|
||||
static noImage = "you need to provide an image to mirror!";
|
||||
static command = "mirror";
|
||||
}
|
||||
|
||||
module.exports = WooWCommand;
|
Loading…
Add table
Add a link
Reference in a new issue