DropModifier
DropModifier ⇐ KeepModifier
A DropModifier will "drop" (Remove from total calculations) dice from a roll.
Kind: global class
Extends: KeepModifier
See: KeepModifier for the opposite of this modifier
- DropModifier ⇐
KeepModifier- new DropModifier([end], [qty])
- .order :
number - .name ⇒
string - .notation ⇒
string - .rangeToDrop(_results) ⇒
Array.<number>
new DropModifier([end], [qty])
Create a DropModifier instance.
Throws:
RangeErrorEnd must be one of 'h' or 'l'TypeErrorqty must be a positive integer
| Param | Type | Default | Description |
|---|---|---|---|
| [end] | string | "l" | Either `h |
| [qty] | number | 1 | The amount of dice to drop |
dropModifier.order : number
The default modifier execution order.
Kind: instance property of DropModifier
dropModifier.name ⇒ string
The name of the modifier.
Kind: instance property of DropModifier
Returns: string - 'drop-l' or 'drop-h'
dropModifier.notation ⇒ string
The modifier's notation.
Kind: instance property of DropModifier
dropModifier.rangeToDrop(_results) ⇒ Array.<number>
Determine the start and end (end exclusive) range of rolls to drop.
Kind: instance method of DropModifier
Returns: Array.<number> - The min / max range to drop
| Param | Type | Description |
|---|---|---|
| _results | RollResults | The results to drop from |