Recipe types from shared scripts and stuff
This commit is contained in:
@@ -10,6 +10,7 @@ import { block_variant } from "$/common/block_models.ts";
|
||||
import { load_worldgen } from "$/common/worldgen_loader.ts";
|
||||
import { create_mod } from "$/tools/new_mod.ts";
|
||||
import { PLAYER_MENU_CRAFTING, PROTOCOL_VERSION } from "$/common/protocol.ts";
|
||||
import { recipe_lookup } from "$/common/mod_loader.ts";
|
||||
import { container_items, copy_dir, test_game } from "./helpers.ts";
|
||||
|
||||
// mods/bworld plus a mod made from the template, in a temp folder
|
||||
@@ -31,8 +32,8 @@ Deno.test("the base game loads from mods/bworld", async () => {
|
||||
assert(EverythingRegistry.get<ItemRegistry>("items", "bworld:stone"));
|
||||
assert(EverythingRegistry.get<ItemRegistry>("items", "bworld:coal"));
|
||||
assert(game.recipes.shaped.some((recipe) => recipe.result.id === "bworld:oak_planks"));
|
||||
assert(game.recipes.furnace.has("bworld:iron_ore"));
|
||||
assert(game.recipes.fuel.has("bworld:coal"));
|
||||
assert(recipe_lookup(() => game.recipes).find("bworld:smelting", "bworld:iron_ore"));
|
||||
assert(recipe_lookup(() => game.recipes).find("bworld:fuel", "bworld:coal"));
|
||||
assertEquals(EverythingRegistry.get<BlockRegistry>("blocks", "bworld:water")?.replaceable, true);
|
||||
// still has its code until it's a component
|
||||
assert(EverythingRegistry.get<ItemRegistry>("items", "bworld:copper_watering_can")?.on_create);
|
||||
|
||||
Reference in New Issue
Block a user