Reference · Pipes, rules and solving
SHAPE_MASKSconstant
A piece of each shape facing north, as the drawings and the tests name them.
Import it
import { SHAPE_MASKS } from "@johnmorrisdotca/suido";
Definition
const SHAPE_MASKS: Record<Shape, number> = {
blank: 0,
end: NORTH,
straight: NORTH | SOUTH,
elbow: NORTH | EAST,
tee: NORTH | EAST | SOUTH,
cross: 15,
}
Members
| Name | Type | Description |
|---|---|---|
end | number | |
straight | number | |
elbow | number | |
tee | number | |
blank | number | |
cross | number |
Examples
import { SHAPE_MASKS } from "@johnmorrisdotca/suido";
console.log(SHAPE_MASKS);{ blank: 0, end: 1, straight: 5, elbow: 3, tee: 7, cross: 15 }What it prints (run when this page was built)