21 lines
745 B
JavaScript
21 lines
745 B
JavaScript
|
const wrap = require("../../utils/wrap.js");
|
||
|
const ImageCommand = require("../../classes/imageCommand.js");
|
||
|
|
||
|
class SonicCommand extends ImageCommand {
|
||
|
params(args) {
|
||
|
const cleanedMessage = args.join(" ").replaceAll("&", "\\&").replaceAll(">", "\\>").replaceAll("<", "\\<").replaceAll("\"", "\\"").replaceAll("'", "\\'").replaceAll("%", "\\%");
|
||
|
return {
|
||
|
text: wrap(cleanedMessage, {width: 15, indent: ""})
|
||
|
};
|
||
|
}
|
||
|
|
||
|
static description = "Creates a Sonic speech bubble image";
|
||
|
static arguments = ["[text]"];
|
||
|
|
||
|
static requiresImage = false;
|
||
|
static requiresText = true;
|
||
|
static noText = "you need to provide some text to make a Sonic meme!";
|
||
|
static command = "sonic";
|
||
|
}
|
||
|
|
||
|
module.exports = SonicCommand;
|