Remove duplicate code

This commit is contained in:
2026-10-13 11:57:43 -03:00
parent dfc6a6d77b
commit 5165698fe3
50 changed files with 307 additions and 812 deletions
+2 -4
View File
@@ -7,7 +7,7 @@ import { ItemStack } from "$/common/inventory.ts";
import { bake_model } from "$/common/block_models.ts";
import { validate_recipe } from "$/common/mod_data.ts";
import { get_state_value, set_state_value } from "$/common/utils.ts";
import { test_game } from "./helpers.ts";
import { stone_floor, test_game } from "./helpers.ts";
const POT = [0, 101, 0] as const;
const FURNACE = [0, 100, 0] as const;
@@ -15,9 +15,7 @@ const FURNACE = [0, 100, 0] as const;
async function setup() {
const t = await test_game("mods");
t.join(1, "alice");
for (let x = -3; x <= 3; x++) {
for (let z = -3; z <= 3; z++) t.game.set_block(x, 99, z, "bworld:stone");
}
stone_floor(t.game);
t.send(1, { type: "move", x: 2.5, y: 100, z: 2.5, yaw: 0, pitch: 0 });
t.game.set_block(...FURNACE, "bworld:furnace");
t.game.set_block(...POT, "farmersdelight:cooking_pot");