ReadonlychanceReadonlyexpectedReadonlyframesReadonlytotalwhether the defender would be at 0 hp once every landing strike has been shown
how long the animation runs, in seconds
the frame the animation shows at time, clamped to its own start and end
The numbers an attack dialog shows and animates: the attacker and defender's hp over the course of a blow, plus the totals the labels print.
It deliberately computes no damage of its own - this framework supplies no damage formula, so a game hands in the per-strike
damageexactly as its own rules worked it out. What the preview adds is the part a dialog needs and a formula does not: the timeline (one frame per strike,sampleAtthe animation's own clock) and the two totals (the maximum,damage * strikes, and the expected value oncechanceToHitis weighed). Which strikes actually land ishits, so a preview can show the maximum by default or a known outcome a replay already rolled.Example