diff --git a/gameutils.py b/gameutils.py index da74560..acbbf23 100644 --- a/gameutils.py +++ b/gameutils.py @@ -99,11 +99,14 @@ class gameutils(commands.Cog): default_member_permissions=nextcord.Permissions(manage_roles=True), ) @nextcord.ext.application_checks.has_permissions(manage_roles=True) - async def turngen(self, interaction: nextcord.Interaction, number: int, sides: int, hidden: str = nextcord.SlashOption(choices={"Yes": True, "No": False})): + async def turngen(self, interaction: nextcord.Interaction, number: int, sides: int, hidden: str = nextcord.SlashOption(choices=["Yes", "No"])): message = f"May the odds ever be in your favor...\n" for d in range(number): - message = message + f":game_die:1. {str(random.randint(1, sides))}" - await interaction.response.send_message(message, ephemeral=hidden) + message = message + f":game_die:{str(d+1)}. {str(random.randint(1, sides))}\n" + if hidden == "Yes": + await interaction.response.send_message(message, ephemeral=True) + else: + await interaction.response.send_message(message, ephemeral=False)