roll_batch
Roll multiple dice expressions at once and receive all results in a single structured response. Use for combat rounds, character creation, and multiple checks.
Instructions
Roll multiple different dice expressions in a single efficient operation.
PURPOSE: Use this tool when you need to make several different dice rolls at once. Instead of calling the roll tool multiple times, batch them together for efficiency and to receive all results in a single structured response. Perfect for combat rounds, character creation, or any scenario requiring multiple distinct rolls.
WHEN TO USE:
Combat rounds: Roll attack, damage, and saving throws together
Character creation: Roll all 6 ability scores at once (6x "4d6kh3")
Multiple checks: Roll several different ability checks simultaneously
Efficiency: When you need 3+ different rolls, batching is more efficient
Organized results: Get all rolls back in a structured array
Mixed roll types: Different expressions with different modifiers/mechanics
WHEN NOT TO USE:
Single roll (use roll instead)
Need detailed AST for each roll (call roll_detailed multiple times)
Rolls are dependent on each other (roll one, check result, then decide next roll)
ERROR HANDLING: Each roll in the batch is evaluated independently. If one expression fails, it returns an error entry, but other rolls continue. Check the "success" field for each result:
success: true → Roll succeeded, has "total" and "result"
success: false → Roll failed, has "error" message
COMMON EXAMPLES:
Combat Round: ["1d20+5", "2d6+3", "1d20+2"] → Attack roll, damage roll, saving throw
Character Creation (6 ability scores): ["4d6kh3", "4d6kh3", "4d6kh3", "4d6kh3", "4d6kh3", "4d6kh3"] → Roll all six ability scores at once
Party Ability Checks: ["1d20+3", "1d20+1", "1d20+5", "1d20+0"] → Perception checks for 4 party members
Mixed Damage Types: ["2d6", "1d8", "3d4+2"] → Sword damage, fire damage, poison damage
With Advantage/Disadvantage: ["2d20kh1+5", "2d20kl1+2"] → Attack with advantage, save with disadvantage
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| expressions | Yes | Array of dice expressions to evaluate | |
| allow_comments | No | Allow comments after each expression |