mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
fixed randrange for roll
This commit is contained in:
parent
3548775b18
commit
75887d5ab3
1 changed files with 2 additions and 2 deletions
|
@ -459,7 +459,7 @@ Sintassi: `/roll <max>`"""
|
|||
parse_mode="Markdown")
|
||||
return
|
||||
# Roll the dice!
|
||||
await update.message.reply(bot, f"*Numero generato:* {random.randrange(0, arguments[0]) + 1}")
|
||||
await update.message.reply(bot, f"*Numero generato:* {random.randrange(0, int(arguments[0])) + 1}")
|
||||
|
||||
|
||||
async def roll_discord(bot, message, arguments):
|
||||
|
@ -471,7 +471,7 @@ Sintassi: `!roll <max>`"""
|
|||
await bot.send_message(message.channel, "⚠ Sintassi del comando non valida.\n`!roll <max>`")
|
||||
return
|
||||
# Roll the dice!
|
||||
await bot.send_message(message.channel, f"*Numero generato:* {random.randrange(0, arguments[0]) + 1}")
|
||||
await bot.send_message(message.channel, f"*Numero generato:* {random.randrange(0, int(arguments[0])) + 1}")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
Loading…
Reference in a new issue