Files
amane-tanikaze-dcbot/commands/utils/help.ts
2024-10-13 14:50:19 +00:00

30 lines
954 B
TypeScript

import {CommandInteraction, EmbedBuilder} from 'discord.js';
import {Command} from '../../classes/command';
import {logger} from '../../logger';
import {config} from '../../config';
class Help extends Command{
get name(){return "help";}
get description(){return "Help messages.";}
async execute(interaction: CommandInteraction): Promise<void>{
const embed = new EmbedBuilder()
.setTitle("Help message")
.setDescription(`Report issues on [this page](${config.urls.issue})`)
.setColor(0x1f1e33)
.setAuthor({
name: 'Ian Shih (konchin)',
url: config.urls.author,
iconURL: config.urls.icon
})
.setFields(
{name: 'Read the documentation', value: config.urls.help},
{name: 'Read the source code', value: config.urls.git}
);
await interaction.reply({embeds: [embed], ephemeral: true});
logger.log(`Command: help`);
}
};
export const command = new Help();