Skip to the content

Kyuubuキューブ

Turn CSS 3D cubes by touch, keys or notation, reproduce a scramble from a seed, and follow a solve one named step at a time.

Kyuubu (キューブ) is the Japanese spelling of cube. About the name

Contents

Reference · Cube engine and views

ReplaySourcetype

What a replay is made from.

Import it

import type { ReplaySource } from "@johnmorrisdotca/kyuubu";

Definition

type ReplaySource = {
    size?: number;
    scramble: string;
    solution: string;
    timeMs?: number;
    stepMs?: readonly number[];
};

Members

NameTypeDescription
size (optional)number | undefined

The cube's side: 3 when left out.

scramblestring

The scramble, as written.

solutionstring

The solve, as written; comments and brackets are skipped.

timeMs (optional)number | undefined

How long the solve took, in milliseconds, when that is known.

stepMs (optional)readonly number[] | undefined

How long each step of the solution took, in milliseconds, when that is known; one for every step.

Examples

import type { ReplaySource } from "@johnmorrisdotca/kyuubu";


const value: ReplaySource = { size: 3, scramble: "R", solution: "R'", timeMs: 1000 };
console.log(value.timeMs);
1000

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/kyuubu 1.14.1.