Flows
Flows chain an initial roll to a follow-up roll using the -> operator. The follow-up is preloaded but not auto-rolled, giving the player control over when to execute it. This mirrors actual table play — roll attack, see the result, then roll damage.
Syntax
attack_expr -> damage_expr (trigger ? result_expr [: next_cond])
The conditional is a parenthesized expression that resolves based on a trigger. The parser resolves all parentheses first, evaluates the trigger against the preceding roll, and splices the result into the damage expression. The result can be anything — crit flags, extra dice, modifiers, or any combination. If no trigger matches, the conditional resolves to nothing.
Triggers
| Trigger | Description | Example |
|---|---|---|
n20 | Natural die value equals 20 | (n20?c) |
n{19,20} | Natural die in explicit set | (n{19,20}?c) |
n[18..20] | Natural die in range | (n[18..20]?c) |
t24 | Modified total equals 24 | (t24?c) |
t{24,25} | Modified total in set | (t{24,25}?c) |
<n> | User-toggled named parameter | (<smite>?+2d8) |
s<n> | Inherit selection from prior box | (s<gwm>?+10) |
See Natural and Total Triggers and Named Parameters for details.
Nested Conditions
Conditions nest using colon as an else-separator, following ternary operator conventions:
d20+4->2d6(n20?C:(n19?c))+3
If natural 20: Perkins crit. Else if natural 19: normal crit. Otherwise: standard damage.
d20+11->2d6(n20?C:(n[18..19]?c))+5
Champion fighter (level 18) with expanded crit range 18–20, Perkins crit on nat 20 only.
UX Behavior
Each segment of a flow is presented as a separate modal box:
- Box 1 (Attack): Tapping the favorite executes the attack roll and displays the result. Long-press shows toggles for any Named Parameters in this segment.
- Box 2 (Damage): Appears preloaded with crit state already applied based on the trigger evaluation. Tap to roll. Long-press shows toggles for this segment’s named parameters (parameters from Box 1 using
s<n>are inherited silently).
This keeps the player in control — the DM may override a hit, a Shield spell may be cast, etc.
Examples
| Scenario | Notation |
|---|---|
| Longsword attack+damage | d20+5->d8(n20?c)+3 |
| Advantage flow, Perkins crit | 2d20kh+5->d8(n20?C)+3 |
| Champion fighter | d20+11->2d6(n20?C:(n[18..19]?c))+5 |
| Paladin+GWM (parameterized) | (<adv>?2d20kh:(<dis>?2d20kl:d20))(<gwm>?-5)+4->(d8(<smite>?+2d8))(n20?c)+3(s<gwm>?+10) |
See also: Named Parameters, Crit Mechanics, Notation Spec