Moved subcommand builder to their files

This commit is contained in:
2025-03-23 15:01:08 +01:00
parent 95f9bb723f
commit 62a56e3c1c
10 changed files with 108 additions and 104 deletions

View File

@@ -1,9 +1,35 @@
import { SlashCommandSubcommandBuilder } from "discord.js"
import { devMessage, embedColor } from "~/config/options"
import { IGuildData, SubCommand } from "~/typings"
import { numberFormatter } from "~/utils/Functions/intlFormaters"
import { getGuild, getIGN, getPlayer, getUUID } from "~/utils/Hypixel"
import { redis } from "~/utils/Illegitimate"
export const topSub = new SlashCommandSubcommandBuilder()
.setName("top")
.setDescription("Get the top guild members based on gexp")
.addStringOption(option =>
option
.setName("query")
.setDescription("The query to search for. [Default: player]")
.setRequired(true)
)
.addStringOption(option =>
option
.setName("type")
.setDescription("The type of query.")
.addChoices(
{ name: "Guild Member", value: "ign" },
{ name: "Guild Name", value: "name" },
{ name: "Guild Id", value: "id" }
)
)
.addNumberOption(option =>
option
.setName("amount")
.setDescription("The amount of guild members to show. [Default: 10]")
)
const cmd: SubCommand = async (interaction) => {
await interaction.deferReply()