Closed brentleyjones closed 8 years ago
End result of this should look something like:
expression = 2 * 2d(20) + 8
let max = expression.max() // 88
let min = expression.min() // 10
?
Yes
Except it might only work when wrapping the die. I'm not sure it will know how to look deeper and say to max each expression.
Maybe to support this expressions will have to expose ranges. It can be inferred from the probability mass of the expression it wraps I guess.
Yeah I was thinking something with the probability mass. It's practically given at that point.
I think probability mass is the best thing to grace this project.
Given an expression that can produce multiple results, like
Die
, we need expressions that produce the min or maximum of that expression. Useful in some systems that on certain conditions, like critical hits, maximize all of the dice rolled.