Oh hey, D&D! I also once wrote a roller: http://dnd.nilamo.com/
It's different from what you're working on, though, as mine was made for character generation (roll 4d6, 6 times for a row, for 6 rows to make a grid, reroll all 1s, and add the three highest numbers to get a stat, then choose any row/column for your base stats).
It's different from what you're working on, though, as mine was made for character generation (roll 4d6, 6 times for a row, for 6 rows to make a grid, reroll all 1s, and add the three highest numbers to get a stat, then choose any row/column for your base stats).
(Aug-07-2017, 08:32 PM)MaxAim Wrote: I thought about that, but I don't really know how to do thatSomething like:
>>> response = input("Roll: ") Roll: 2d20 >>> number_of_dice, type_of_dice = map(int, response.lower().split("d")) >>> number_of_dice 2 >>> type_of_dice 20