mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-21 10:47:04 +02:00
17 lines
501 B
TypeScript
17 lines
501 B
TypeScript
import { SlashCommandStringOption } from 'discord.js';
|
|
import { range } from 'lodash';
|
|
import numberToRomanNumeral from '../blitz/numberToRomanNumeral';
|
|
|
|
export default function addTierChoices(option: SlashCommandStringOption) {
|
|
return option
|
|
.setName('tier')
|
|
.setDescription('The tier you want to see')
|
|
.setChoices(
|
|
...range(10, 0).map((tier) => ({
|
|
name: `Tier ${tier} - ${numberToRomanNumeral(tier)}`,
|
|
value: `${tier}`,
|
|
})),
|
|
)
|
|
.setRequired(true);
|
|
}
|