TravBot-v3/src/commands/utility/emote.ts

19 lines
641 B
TypeScript

import Command from "../../core/command";
import {queryClosestEmoteByName} from "./modules/emote-utils";
import {botHasPermission} from "../../core/libd";
import {Permissions} from "discord.js";
export default new Command({
description: "Send the specified emote.",
run: "Please provide a command name.",
any: new Command({
description: "The emote(s) to send.",
usage: "<emotes...>",
async run({guild, channel, message, args}) {
let output = "";
for (const query of args) output += queryClosestEmoteByName(query).toString();
channel.send(output);
}
})
});