Shasha/cmds/image/cry.js
2021-06-28 17:12:34 +09:00

23 lines
No EOL
770 B
JavaScript

'use strict';
const commando = require("@iceprod/discord.js-commando");
const { trySend, defaultImageEmbed } = require("../../resources/functions");
const { default: fetchNeko } = require("nekos-best.js");
module.exports = class cry extends commando.Command {
constructor(client) {
super(client, {
name: "cry",
memberName: "cry",
group: "image",
description: "Are you sad? :("
});
}
async run(msg) {
msg.channel.startTyping();
const title = `${msg.guild ? msg.member.displayName : msg.author.username} is crying :<`;
const image = await fetchNeko("cry");
const emb = defaultImageEmbed(msg, image, title);
return trySend(this.client, msg, emb);
}
};