DiceRoll class

A dice roll, containing the dice that was rolled and the results of the individual dice.

Constructors

DiceRoll({required Dice dice, required List<int> results})

Properties

dice → Dice
final
didHitNaturalMax → bool
Represents whether or not the dice roll was a critical hit, meaning that the highest possible value was rolled.
no setter
hashCode → int
The hash code for this object.
no setterinherited
indexOfNaturalMax → int
If the dice roll was a critical hit, this returns the index of the dice that was the critical hit.
no setter
results → List<int>
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
total → int
The total of the dice roll, including the modifier.
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

roll(Dice dice) → DiceRoll
Rolls a single dice and returns the result.
rollMany(List<Dice> dice) → List<DiceRoll>
Rolls a list of dice and returns a list of dice rolls.