How the Dice Roller Rolls Each Die
AnyTool Dice Roller rolls every die in the browser using the Web Crypto API. A die of S sides is produced as secureRandomInt(S) + 1, where the integer in [0, S) comes from crypto.getRandomValues via rejection sampling — values that would fall outside an even multiple of S are discarded — so there is no modulo bias and every face is exactly equally likely. Math.random is never used. Build a pool of mixed dice (d4, d6, d8, d10, d12, d20, d100) with a quantity per type and a flat +/− modifier, or type standard dice notation that an in-page parser turns into signed terms and rolls. Each roll plays a short CSS tumble animation, then shows every individual die (pips for a d6, the number for others), per-group subtotals and the grand total.
- Each die = secureRandomInt(sides) + 1 from crypto.getRandomValues (CSPRNG)
- Rejection sampling removes modulo bias — every face is exactly equally likely
- Math.random is never used for any roll
- Mixed dice pools (d4–d100) with quantity per type and a flat modifier
- All rolls run client-side — no server round-trip
