aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorGravatar jesopo2018-11-17 12:21:09 +0000
committerGravatar jesopo2018-11-17 12:21:09 +0000
commit0f8a3231c66eb037d5f46ea689f6ccd971457155 (patch)
treed1905d685998ac39ad87b73e785968b6d4f4622c /modules
parent.partition returns 3 values! (diff)
signature
Should be using `sides` and `count`, not `roll[0]` and `roll[1]`
Diffstat (limited to 'modules')
-rw-r--r--modules/dice.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/dice.py b/modules/dice.py
index 8923c51c..18eabeb2 100644
--- a/modules/dice.py
+++ b/modules/dice.py
@@ -15,8 +15,8 @@ class Module(ModuleManager.BaseModule):
if not count.isdigit() or not sides.isdigit():
raise utils.EventError(ERROR_FORMAT)
- count_n = min(int(roll[0]), 5)
- sides_n = min(int(roll[1]), 20)
+ count_n = min(5, int(count))
+ sides_n = min(20, int(sides))
reults = random.choices(range(1, die_sides), k=die_count)