Fill on serverworld and clear out tiles on new day

This commit is contained in:
2026-11-22 11:22:07 -03:00
parent dfb110e0f8
commit c2e885f23a
8 changed files with 64 additions and 18 deletions
+3
View File
@@ -437,6 +437,9 @@ export interface ServerWorld {
// runs on_break / on_create, synced to everyone. states are the ones it's placed with, the rest keep their defaults,
// like minecraft's setBlock with a block state: a shaft turned into an encased one keeps its axis
set_block(x: number, y: number, z: number, id: Id, states?: Record<string, number>): boolean;
// every block between two corners, both included, set to id like set_block, like a schematic all at once: they all
// change before any of them hears of it. parts above or below the world are left out. says how many it changed
fill(from: Position, to: Position, id: Id): number;
// like breaking it by hand without a tool: on_break, then its drops, which it returns (copies). undefined when there
// was nothing to break. see BreakOptions for machines breaking it
break_block(x: number, y: number, z: number, options?: BreakOptions): ItemStack[] | undefined;