UNPKG

@randsum/5e

Version:

A flexible, type-safe dice roller for building 5e-compatible applications

10 lines (8 loc) 229 B
import { roll5e } from './roll5e' import type { RollArgument5e } from './types' export function meetOrBeat5e( difficultyClass: number, rollArg: RollArgument5e ): boolean { return roll5e(rollArg).total >= difficultyClass }