bellsOf関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
One bell for every engine the pieces already draw. The mouth is the first point of the bell.
インポート
import { bellsOf } from "@johnmorrisdotca/uchusen-rockets";
定義
function bellsOf(pieces: readonly Piece[]): Bell[]
引数
| 名前 | 型 | 説明 |
|---|---|---|
pieces | readonly Piece[] | The pieces of a part, as the builder makes them. |
戻り値
Bell[]
The bells, one for each engine the pieces already draw.
例
import { build } from "@johnmorrisdotca/uchusen-rockets/build";
import { bellsOf } from "@johnmorrisdotca/uchusen-rockets";
const booster = build({ rocket: "falcon-9", variant: "block-5" }).parts[0];
console.log(booster ? bellsOf(booster.pieces).length : 0);9出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。