From d115510042988967394001bf0f459bfc87e0efbc Mon Sep 17 00:00:00 2001 From: justuswolff Date: Mon, 16 Feb 2026 20:37:52 +0100 Subject: [PATCH] add failsafe to newdesign --- src/main.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.lua b/src/main.lua index 567d47a..8186d1f 100644 --- a/src/main.lua +++ b/src/main.lua @@ -112,7 +112,7 @@ local function newdesign() term.setCursorPos(x, z) if currentbuf == 1 then -- wall term.blit(" ", colors.toBlit(colors.white), colors.toBlit(colors.white)) - elseif currentbuf > 1 then -- blocks + elseif currentbuf and currentbuf > 1 then -- blocks renderblock(currentbuf-1) --term.blit("C", colors.toBlit(colors.black), colors.toBlit(colors.red)) elseif currentbuf == 0 or currentbuf == nil then -- nothing