You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'd like to know within the results what die was rolled to get that result.
Basically my main use case is I'd like to highlight high/low rolls of the "natural die", similar to cs or cf modifiers but I'd like to do it globally to all dice without requiring cfcs on everything and in my UI not within the output string as notation. Also a less important but potentially useful use case would be showing the user what individual roll results are from different dice and allowing individual die rerolls after the roll results without having to have them type in new notation. Practical example might be selecting low dice to reroll for Empowered Spell in 5e.
The "Annotated" line is a rough idea of what I want to make:
I checked the docs and I don't see anything like this, right now I'd have to run my own version of the Parser.parse and compare it to DiceRoll.roll() array. Looking for just the raw dice info such as number of sides.
Let me know if I just missed something that covers my needs or if something like this would be useful as a contribution!
{"rolls": [{"calculationValue": 5,"initialValue": 5,"modifierFlags": "","modifiers": [],"type": "result","useInTotal": true,"value": 5// something like this, which is already available from `Parser.parse()`"sides": 20,},{"calculationValue": 14,"initialValue": 14,"modifierFlags": "","modifiers": [],"type": "result","useInTotal": true,"value": 14// something like this, which is already available from `Parser.parse()`"sides": 20,}],"type": "roll-results","value": 19}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'd like to know within the results what die was rolled to get that result.
Basically my main use case is I'd like to highlight high/low rolls of the "natural die", similar to
cs
orcf
modifiers but I'd like to do it globally to all dice without requiringcfcs
on everything and in my UI not within the output string as notation. Also a less important but potentially useful use case would be showing the user what individual roll results are from different dice and allowing individual die rerolls after the roll results without having to have them type in new notation. Practical example might be selecting low dice to reroll for Empowered Spell in 5e.The "Annotated" line is a rough idea of what I want to make:
I checked the docs and I don't see anything like this, right now I'd have to run my own version of the
Parser.parse
and compare it toDiceRoll.roll()
array. Looking for just the raw dice info such as number of sides.Let me know if I just missed something that covers my needs or if something like this would be useful as a contribution!
Beta Was this translation helpful? Give feedback.
All reactions