Update
This commit is contained in:
parent
f5758968f4
commit
3924ec5955
1 changed files with 5 additions and 1 deletions
|
@ -160,8 +160,12 @@ class gameutils(commands.Cog):
|
||||||
)
|
)
|
||||||
async def diceroll(self, interaction: nextcord.Interaction, number: int, sides: int, hidden: str = nextcord.SlashOption(choices=["Yes", "No"])):
|
async def diceroll(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"
|
message = f"May the odds ever be in your favor...\n"
|
||||||
|
fullnum = 0
|
||||||
for d in range(number):
|
for d in range(number):
|
||||||
message = message + f":game_die: {str(d+1)}. {str(random.randint(1, sides))}\n"
|
num = random.randint(1, sides)
|
||||||
|
fullnum = fullnum + num
|
||||||
|
message = message + f":game_die: {str(d+1)}. {str(num)}\n"
|
||||||
|
message = message + f"sum: {fullnum}"
|
||||||
if hidden == "Yes":
|
if hidden == "Yes":
|
||||||
await interaction.response.send_message(message, ephemeral=True)
|
await interaction.response.send_message(message, ephemeral=True)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue