Make force rarity configurable
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
1a4d4b4e23
commit
ada907e2a4
7 changed files with 31 additions and 2 deletions
|
@ -16,7 +16,11 @@ export default class Drop extends Command {
|
|||
}
|
||||
|
||||
public override async execute(interaction: CommandInteraction) {
|
||||
const randomCard = await CardDropHelper.GetRandomCard();
|
||||
let randomCard = await CardDropHelper.GetRandomCard();
|
||||
|
||||
if (process.env.DROP_RARITY && Number(process.env.DROP_RARITY) > 0) {
|
||||
randomCard = await CardDropHelper.GetRandomCardByRarity(Number(process.env.DROP_RARITY));
|
||||
}
|
||||
|
||||
const image = readFileSync(randomCard.Path);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue