RPG Dice Roller

The RPG Dice Roller is a random number generator, using dice notation, for table top Role Playing Games (TTRPG) like Dungeons and Dragons.

Dice Notation

Dice Notation is a way of specifying different dice rolls, in the form of...

[number of dice]d[size of dice][optional modifier].

For instance, if you wanted to roll one standard six sided dice, you would write it as "1d6" in dice notation. The "d" in the middle stands for "dice". The number before the "d" indicates how many dice to roll. In this case, one dice. The number after the "d" indicates the type of dice as determined by the number of faces it has. In this case it's a six sided dice, so the number is "6".

If you wanted to roll more dice, rolling a six sided dice twice for example, you would write it as 2d6.

Sometimes a modifier is added to the end of the notation. 1d6+1 would mean you should roll one six sided dice, then add 1 to the result, giving a result of 2 to 7, inclusive.

Dice modifiers can also be negative, so 1d6-1 is also fine, giving a result of 0 to 5.

Common die types used in gaming are 4, 6, 8, 10, 12, 20, or 100. The RPG Dice Roller is virtual so you don't have to be constrained by the physics of real world dice. There's no reason you couldn't roll a 3 sided die (1d3), or a million sided die (1d1000000).

Some examples of dice notation using different kinds of dice:

1d20
Roll one twenty sided dice
Roll one four sided die
Roll a six sided die three times, and sum the result
Sum two eight sided dice, then add three
Roll a hundred sided dice. Useful for percentages
Shorthand for 1d100

You can add modifiers to rolls, but they must be signed with a + or - sign. e.g...

Roll one ten sided die, and subtract one
1d12+3
Roll a twelve sided dice, then add three
1d100+12
Roll a hundred sided dice, then add twelve
2d6-1
Roll two six sided dice, then subtract one

You can also batch rolls. If you want to roll three separate d6 rolls, you can use "1d6*3" which will return three numbers.
The following are all valid rolls...

Roll one twenty sided die and add five, then roll it all again a second time
2d8+1*3
Roll two eight sided dice then add one, then repeat the roll three times

The Dice Roller can also batch rolls using a non-standard comma seperated list. You could use "1d6,1d6,1d6", which will return three numbers. But you can use the comma separated list to roll different types of dice.
The following are all valid rolls...

1d20,1d8
Roll a twenty sided dice, then roll an eight sided dice
1d20,1d8+1,1d6
Roll a twenty sided die, then roll an eight sided die and add one, then roll a six sided die
1d100+10*3,3d6+1
This one's a doozy. Roll a hundred sided dice then add ten, then roll it again three times. Then roll three six sided dice and add one to the result.