From 0da0349994c804e985c127eb2de05ddb029f680f Mon Sep 17 00:00:00 2001 From: Nix Krystik Date: Tue, 11 Aug 2026 19:34:04 +0800 Subject: [PATCH] (rewrite): Add `/about` command. --- src/commands/utilities/about.ts | 42 +++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 src/commands/utilities/about.ts diff --git a/src/commands/utilities/about.ts b/src/commands/utilities/about.ts new file mode 100644 index 0000000..b41c93a --- /dev/null +++ b/src/commands/utilities/about.ts @@ -0,0 +1,42 @@ +// External Imports +import { Command, CommandBuilder, CommandClient, CommandInteraction, Constants, SlashCommand } from 'athena-prime'; + +// Internal Imports +import { CreateDefaultEmbed } from '../../utils'; + +// --------------- + +@SlashCommand( + new CommandBuilder('about', 'View information about Hexerade!') + .setIntegrationTypes(Constants.ApplicationIntegrationType.GuildInstall) + .setContexts(Constants.InteractionContextType.Guild) + .setCommandType(Constants.ApplicationCommandType.ChatInput) +) +class AboutCommand extends Command { + cooldown = 60; + + async handleCommand(context: CommandClient, interaction: CommandInteraction, data: any) { + if (!interaction.inGuild()) return; + + await interaction.createMessage({ + embeds: [{ + ...CreateDefaultEmbed(context), + + description: "I'm the very cool bot for the e621 Discord.", + + fields: [ + { name: 'Members', value: `${interaction.guild.memberCount}`, inline: true }, + { name: 'Boosts (Tier)', value: `${interaction.guild.premiumSubscriptionCount} (${interaction.guild.premiumTier})`, inline: true }, + + { name: 'Developer', value: 'tarrgon.', inline: false }, + { name: 'Contributor', value: 'nxbat', inline: false }, + + { name: 'Terms of Use', value: 'https://e621.net/terms_of_use', inline: false }, + { name: 'Privacy Policy', value: 'https://e621.net/static/privacy/discordbot', inline: false }, + ] + }] + }); + } +} + +export default new AboutCommand('about'); \ No newline at end of file