From 39ca197edd2202c98b79f000ba34cf3b402aa89a Mon Sep 17 00:00:00 2001 From: Justus Wolff Date: Sun, 15 Feb 2026 11:41:52 +0100 Subject: [PATCH] change camera bound checking --- src/main.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.lua b/src/main.lua index bf590dd..e6e91d3 100644 --- a/src/main.lua +++ b/src/main.lua @@ -187,13 +187,13 @@ local function newdesign() if keys.getName(event[2]) == "w" and camy < dimensions["z"] then -- pan up camy = camy + 1 end - if keys.getName(event[2]) == "s" and camy > 0 then -- pan down + if keys.getName(event[2]) == "s" and camy > -dimensions["z"] then -- pan down camy = camy - 1 end if keys.getName(event[2]) == "a" and camx < dimensions["x"] then -- pan left camx = camx + 1 end - if keys.getName(event[2]) == "d" and camx > 0 then -- pan right + if keys.getName(event[2]) == "d" and camx > -dimensions["z"] then -- pan right camx = camx - 1 end end