stepPhase関数
リファレンスの説明と例は英語です。見出しと目次は日本語です。
Which phase a step is in on day, and how far through that phase. Nothing before it starts or after it finishes.
インポート
import { stepPhase } from "@johnmorrisdotca/uchusen-rockets";
定義
function stepPhase(step: PlayStep, day: number): { phase: BuildPhase; along: number; } | null
引数
| 名前 | 型 | 説明 |
|---|---|---|
step | PlayStep | The build step. |
day | number | Days after the keel was laid. |
戻り値
{ phase: BuildPhase; along: number; } | null
The phase, or null when the step is not underway.
例
import { stepPhase } from "@johnmorrisdotca/uchusen-rockets";
console.log(stepPhase({ slot: "drive", start: 0, days: 100 }, 4)?.phase);bring出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。