Reference · Rockets, variants, parts and the fit check
shipPiecesfunction
The pieces of a whole ship: every module in its place, with clamps from the spine to the modules hung beside it. A ship's mesh is these pieces.
Import it
import { shipPieces } from "@johnmorrisdotca/uchusen-rockets";
Definition
function shipPieces(ship: ShipList, options?: ModuleOptions): Piece[]
Parameters
| Name | Type | Description |
|---|---|---|
ship | ShipList | A ship's list of places. |
options (optional) | ModuleOptions | What to draw, for every module. |
Returns
Piece[]
The pieces, in metres, the bottom of the spine at y = 0.
Examples
import { shipPieces } from "@johnmorrisdotca/uchusen-rockets";
const pieces = shipPieces([{ module: "tank-cryo-12" }], { detail: 0.5 });
console.log(pieces.length > 100);trueWhat it prints (run when this page was built)