Skip to the content

Korokoroコロコロ

Roll mixed dice or type notation, compare exact probabilities, keep a history and replay seeded rolls.

Korokoro describes something small rolling in Japanese. About the name

Contents

Reference · Rolls and exact odds

shareQueryManyfunction

A set of rolls as a link: the notation with its 6#, and every roll's faces, the rolls parted by semicolons.

Import it

import { shareQueryMany } from "@johnmorrisdotca/korokoro";

Definition

function shareQueryMany(rolls: readonly Roll[]): string

Parameters

NameTypeDescription
rollsreadonly Roll[]

Completed rolls, or the number of attempts where this parameter is numeric.

Returns

string

A set of rolls as a link: the notation with its 6#, and every roll's faces, the rolls parted by semicolons.

Examples

import { shareQueryMany } from "@johnmorrisdotca/korokoro";
import { normalizeSpec, rollFrom } from "@johnmorrisdotca/korokoro";
const spec = normalizeSpec({ count: 2, sides: 6 });
const sample = rollFrom(spec, [2, 5], "saved", 0, null)!;
console.log(shareQueryMany([sample, sample]));
roll=2%232d6&faces=2%2C5%3B2%2C5&at=0&v=2

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/korokoro 1.16.0.