BudWorks / Akaei

A fun, cute, and modern Discord bot featuring pets, economy, leveling, and more. Built with Discord.js and written in Typescript.
Mozilla Public License 2.0
1 stars 0 forks source link

Create the `/pet battle` command #39

Open JustYourBud opened 2 years ago

JustYourBud commented 2 years ago

The /pet battle command lets the user request to battle another user via their pets. If no pet is specified then a menu is sent to select one, assuming they have more than one. Once the command is sent, Akaei sends a menu to the other user so they can either accept or deny the battle. If they deny, Akaei lets the initiator know that the battle was denied and the command ends. If accepted, the other user needs to select their pet from a menu.

Once the battle has been initiated, whichever pet has the highest speed stat goes first. If both have an equal speed stat, then the user who was challenged gets the first move. The battles themselves are turn-based. Each user selects their move and then that round plays out. Once a pet's health is at 0, the battle ends and the remaining pet wins. If both reach 0 at the same time, the battle ends in a draw. If one user takes too long to respond, the other user wins by default, however it doesn't count as a win for the pet.

Commands

Italics indicate optional options. Command Subcommands Options
/pet battle USER, STRING