D&D 5th Edition
@randsum/fifth — Ability checks, saving throws, attack rolls with advantage/disadvantage.
RANDSUM includes specialized packages for popular tabletop RPG systems. Each game package wraps the core @randsum/roller engine with game-specific validation, roll configuration, and result interpretation.
D&D 5th Edition
@randsum/fifth — Ability checks, saving throws, attack rolls with advantage/disadvantage.
Blades in the Dark
@randsum/blades — Dice pool action rolls with critical, success, partial, and failure outcomes.
Powered by the Apocalypse
@randsum/pbta — 2d6+stat rolls for Dungeon World, Monster of the Week, Apocalypse World, Masks, and more.
Daggerheart
@randsum/daggerheart — Hope and fear dice mechanics with amplification and advantage.
Root RPG
@randsum/root-rpg — 2d6+bonus with Strong Hit, Weak Hit, and Miss outcomes.
Salvage Union
@randsum/salvageunion — D20 table-based rolls for mech combat and salvage operations.
Every game package follows the same pattern using the createGameRoll factory from @randsum/roller:
RollOptions// Each game package exports a `roll()` function with game-specific typesimport { roll } from '@randsum/fifth'
const result = roll({ modifier: 5, rollingWith: 'Advantage' })// result.result is the game-specific outcome (number for D&D 5e)// result.total is the final total// result.rolls contains the raw dice dataAll game packages share these characteristics:
roll() function as the main APIGameRollResult with both raw and interpreted results@randsum/roller (never on each other)Install game packages individually. Each one pulls in @randsum/roller automatically.
# Pick the games you needbun add @randsum/fifthbun add @randsum/bladesbun add @randsum/pbtabun add @randsum/daggerheartbun add @randsum/root-rpgbun add @randsum/salvageunion| Package | Dice | Input | Outcomes |
|---|---|---|---|
@randsum/fifth | 1d20 or 2d20 | modifier + rollingWith | Numeric total |
@randsum/blades | Nd6 pool | count (number) | critical, success, partial, failure |
@randsum/pbta | 2d6 | stat + forward + ongoing + advantage | strong_hit, weak_hit, miss |
@randsum/daggerheart | 2d12 + d6 | modifier + rollingWith + amplify | Hope/Fear outcome + total |
@randsum/root-rpg | 2d6 | bonus (number) | Strong Hit, Weak Hit, Miss |
@randsum/salvageunion | 1d20 | tableName (string) | Table result with label + description |