Skip to the content

Uchusen Rockets宇宙船

Rockets drawn from sourced sizes: line drawings and painted 3D views you drop into a page, take apart and turn round, and a typed model that checks whether a rocket really goes together.

Uchusen is the Japanese word 宇宙船 for spaceship. About the name

Contents

Reference · Rockets, variants, parts and the fit check

spinOffunction

A spin from the spin and way attributes: a name, or seconds a turn. A nonsense value is the default, and a negative one is none.

Import it

import { spinOf } from "@johnmorrisdotca/uchusen-rockets";

Definition

function spinOf(spin: string | null, way: string | null): Spin

Parameters

NameTypeDescription
spinstring | null

The spin attribute: off, slow, medium, fast, or seconds a turn. Null when missing.

waystring | null

The way attribute. Null when missing.

Returns

Spin

The spin to use.

Examples

import { spinOf } from "@johnmorrisdotca/uchusen-rockets";

console.log(spinOf("fast", null), spinOf("30", "ccw"), spinOf("nonsense", null));
{ seconds: 20, way: 'cw' } { seconds: 30, way: 'ccw' } { seconds: 180, way: 'cw' }

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/uchusen-rockets 0.14.0.