MeikyuuMixedLevel型
リファレンスの説明と例は英語です。見出しと目次は日本語です。
A numbered mixed-puzzle recipe and its native difficulty metadata.
インポート
import type { MeikyuuMixedLevel } from "@johnmorrisdotca/meikyuu/levels";
定義
type MeikyuuMixedLevel = Base & {
readonly kind: "mixed";
readonly recipe: MixedRecipe;
};
メンバー
| 名前 | 型 | 説明 |
|---|---|---|
number | number | Its place in its own list, from 1. |
code | string | The recipe as one short word. |
effort | number | What it measures (see |
rating | number | The effort as a rating from 1 to 100 on the scale of the maze list. |
kind | "mixed" | |
recipe | MixedRecipe |
例
import type { MeikyuuMixedLevel } from "@johnmorrisdotca/meikyuu/levels";
import { levelOf } from "@johnmorrisdotca/meikyuu/levels";
const value: MeikyuuMixedLevel = levelOf("mixed",1)!;
console.log(value);{
kind: 'mixed',
number: 1,
code: 'cross:7:4:9675:1|square:5x5:kruskal:to-goal:126',
effort: 41,
rating: 10,
recipe: {
arrows: { shape: 'cross', w: 7, h: 7, longest: 4, seed: 9675, locks: 1 },
maze: {
shape: 'square',
w: 5,
h: 5,
algorithm: 'kruskal',
mode: 'to-goal',
seed: 126
}
}
}出力(このページを作ったときに実行した結果)
この日本語は、まだ日本語を母語とする方の確認を受けていません。訂正を歓迎します。