diff --git a/src/commands/inventory.ts b/src/commands/inventory.ts index 047a898..e0359b2 100644 --- a/src/commands/inventory.ts +++ b/src/commands/inventory.ts @@ -8,11 +8,17 @@ export default class Inventory extends Command { this.CommandBuilder = new SlashCommandBuilder() .setName('inventory') - .setDescription('View your inventory'); + .setDescription('View your inventory') + .addNumberOption(x => + x + .setName('page') + .setDescription('The page to start with')); } public override async execute(interaction: CommandInteraction) { - const embed = await InventoryHelper.GenerateInventoryPage(interaction.user.username, interaction.user.id, 0); + const page = interaction.options.get('page'); + + const embed = await InventoryHelper.GenerateInventoryPage(interaction.user.username, interaction.user.id, page ? Number(page.value) : 0); await interaction.reply({ embeds: [ embed.embed ],