- Make 'S32 modifier' value mandatory even for '!' dice modifier. In order to roll (for example) 5d20! user must from now on type 'cmd 5 20 ! 20' instead of 'cmd 5 20 !', so in fact make a 5d20!20 roll (which should be logic anyway, as it works in the same way). This also allows the explosion value to be modifiable, so expression like 3d25!15 (dice exploding only at 15 instead of only at max, which is 25) is now possible.
- Small change for success rolls: They should count one not only on "less/greater than", but for "equal or less/greater than".
- Added reroll modifier, "r", "r<", "r>". For example "cmd 2 20 r 15" or "cmd 5 10 r< 3".
Sources: https://wiki.roll20.net/Dice_Reference#Roll_Modifiers
- Modifier must be in range from -1000 to 1000.
- Valid modifier types are "+" (bonuses), "-" (penalties), "<", ">" (successes), "!>", "!<" and "!" (explosions).
- Only one modifier type per roll.
- Examples: "rolld 1 20 + 5", "rolld 5 40 > 15", "rolld 10 25 !", "rolld 15 25 !< 10".
- This sub-command has exactly this format: rand(number,number) - no spaces or other character
- Range for both numbers can vary from -200000 to 200000, for example "calc rand(-30,50)", "calc rand(-12345,-700)" or "calc rand(65000,80000)"
- Max always must be bigger, than Min
- Integers only, no floats
- Up to 5 rand(min,max) calls per expression because of performance reasons
- rand() can be mixed with other calc command expressions; For example: "calc 2 + rand(10,40) * 3 / (rand(-90,70) - 20)" or "calc 2 * rand(1,20) + 5" will work
- Nesting rand() in rand() should work fine syntax-wise, like "calc rand(rand(xxx,yyy),rand(zzz,ccc))" - expressions will be calculated from left to right, inner ones first - but if first inner rand() would generate value bigger than second rand(), then the outer rand() will throw a message, that Min must be lower, than Max. Something like "calc rand(rand(1,230),rand(231,500))" is safe because Min in second rand() is higher than Max is first rand(), so the rule will always be met for outer rand()