summaryrefslogtreecommitdiff
path: root/src/commands/fun/howify.ts
diff options
context:
space:
mode:
author8cy <[email protected]>2020-04-16 04:56:37 -0700
committer8cy <[email protected]>2020-04-16 04:56:37 -0700
commit8c435855e647ee7aef8578e253caf91fe44c67cc (patch)
treeae0bb59de10ecec5ca2fc01dfa9190efd1f177ab /src/commands/fun/howify.ts
parentno longer hosting ws, v6.0.4 (diff)
downloaddep-core-8c435855e647ee7aef8578e253caf91fe44c67cc.tar.xz
dep-core-8c435855e647ee7aef8578e253caf91fe44c67cc.zip
The Purification, v7.0.0
add: - aesthetic, oddcase, stretch, surreal - culturedtext - dogeify - howify - insult - lorem - spongebob Other Stuff: - many refactoring
Diffstat (limited to 'src/commands/fun/howify.ts')
-rw-r--r--src/commands/fun/howify.ts32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/commands/fun/howify.ts b/src/commands/fun/howify.ts
new file mode 100644
index 0000000..e7e7eb6
--- /dev/null
+++ b/src/commands/fun/howify.ts
@@ -0,0 +1,32 @@
+import { Command, CommandoMessage } from 'discord.js-commando';
+import how from 'howifier';
+import emoji from 'emoji-random';
+
+module.exports = class HowifyFun extends Command {
+ constructor(client) {
+ super(client, {
+ name: 'howify',
+ aliases: ['how'],
+ group: 'fun',
+ memberName: 'howify',
+ description: 'Howifies any image you send.',
+ userPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY', 'EMBED_LINKS'],
+ clientPermissions: ['SEND_MESSAGES', 'READ_MESSAGE_HISTORY', 'EMBED_LINKS'],
+ examples: ['uwu!howify', 'uwu!how']
+ });
+ }
+ run(msg: CommandoMessage) {
+ if (msg.attachments.size) {
+ // fs.unlinkSync('../../../node_modules/howifier/images/blissgay.jpeg')
+ msg.attachments.forEach(async attachment => {
+ var u1 = await how(attachment.url);
+ setTimeout(() => {
+ msg.say({ files: [u1] })
+ }, 2000);
+ });
+ } else {
+ msg.reply('No image detected. ' + emoji.random())
+ }
+
+ }
+}; \ No newline at end of file