Better recipe api and port smithing to it
This commit is contained in:
@@ -248,7 +248,7 @@ Deno.test("every tier of pickaxe, axe, shovel and hoe exists and can be made", a
|
||||
const { game } = await test_game("mods");
|
||||
const made = new Set([
|
||||
...game.recipes.shaped.map((recipe) => recipe.result.id),
|
||||
...game.recipes.smithing.map((recipe) => recipe.result),
|
||||
...game.recipes.all.flatMap((recipe) => recipe.type === "bworld:smithing" ? [recipe.result] : []),
|
||||
]);
|
||||
for (const tier of ["wood", "stone", "copper", "iron", "gold"]) {
|
||||
for (const tool of ["pickaxe", "axe", "shovel", "hoe"]) {
|
||||
@@ -266,7 +266,7 @@ Deno.test("every tier of watering can exists, can be made and holds more than th
|
||||
const { game } = await test_game("mods");
|
||||
const made = new Set([
|
||||
...game.recipes.shaped.map((recipe) => recipe.result.id),
|
||||
...game.recipes.smithing.map((recipe) => recipe.result),
|
||||
...game.recipes.all.flatMap((recipe) => recipe.type === "bworld:smithing" ? [recipe.result] : []),
|
||||
]);
|
||||
let last = 0;
|
||||
for (const tier of ["wood", "stone", "copper", "iron", "gold"]) {
|
||||
|
||||
Reference in New Issue
Block a user