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

DragPicktype

The layer a drag has picked: its axis and layer, and the way across the screen (a unit vector, x right and y down) that turns it forwards by the right-hand rule. also is the layer beside it that turns with it, where the drag began on the seam between the two.

Import it

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

Definition

type DragPick = {
    axis: CubeAxis;
    layer: number;
    along: [
        number,
        number
    ];
    also?: number;
};

Members

NameTypeDescription
axisCubeAxis
layernumber
along[number, number]
also (optional)number | undefined

Examples

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


const value: DragPick = { axis: 0, layer: 2, along: [1, 0] };
console.log(value.layer);
2

What it prints (run when this page was built)

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