first working command (wolf)

This commit is contained in:
Lio Young 2021-04-20 00:19:57 +02:00
parent 3c8bf5aad8
commit 9b3653eb16
No known key found for this signature in database
GPG Key ID: 789795A11879E169
1 changed files with 8 additions and 2 deletions

View File

@ -1,6 +1,7 @@
import yiff from '../../utils/yiff';
import Command from '../../handler/structures/Command';
import { Context } from '../../utils/types';
import { MessageEmbed } from 'discord.js';
export = class Wolf extends Command {
constructor() {
@ -13,7 +14,12 @@ export = class Wolf extends Command {
}
async command(ctx: Context) {
let image = await yiff.yiffy('animals', "wolf")
console.log(image)
let image = await yiff.thaldrin("wolves")
let provider = "thaldr.in"
ctx.settings.embeds ?
ctx.channel.send(new MessageEmbed().setImage(image.url).setFooter(`Thaldrin - Image provided by ${provider}`, ctx.config.variables.avatar).setColor(ctx.config.variables.color))
:
ctx.channel.send(image.url)
}
}