From 517256b25573b70aadcaa0fb7f2386784f1a2355 Mon Sep 17 00:00:00 2001 From: justuswolff Date: Tue, 17 Feb 2026 22:04:52 +0100 Subject: [PATCH] fix bufistype hopefully... --- src/main.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main.lua b/src/main.lua index d7cd04c..528884f 100644 --- a/src/main.lua +++ b/src/main.lua @@ -75,7 +75,11 @@ local function load(name) return content["buf"],content["dimensions"] end local function bufistype(buf, x,y,z, targettype) - return buf[posasstring(x,y,z)] == targettype or (targettype == 0 and buf[posasstring(x,y,z)] == nil) + if targettype == 0 then + return (buf[posasstring(x,y,z)] == 0) or (buf[posasstring(x,y,z)] == nil) + else + return buf[posasstring(x,y,z)] == targettype + end end local function fill_getneighbors(x,y,z, sx,sz, seltype,buf) local out = {}