From 22301dfe77dca0daea3590d5af718269393f06e4 Mon Sep 17 00:00:00 2001 From: Gabriel Tofvesson Date: Sat, 12 Oct 2024 23:24:41 +0200 Subject: [PATCH] Fix item group rendering --- itemcontroller.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/itemcontroller.lua b/itemcontroller.lua index f157d74..cea4472 100644 --- a/itemcontroller.lua +++ b/itemcontroller.lua @@ -594,13 +594,13 @@ local PAGES = { storageSatProgress:setProgress(1 - (emptyCount / totalCount)) local basePageIndex = (pageState.currentPage - 1) * groupEntryListBudget - local pageEntryCount = math.min(groupEntryListBudget, totalCount - basePageIndex) for i=1,groupEntryListBudget do - local isVisible = i <= pageEntryCount + local group = pageState.stacks[basePageIndex + i] + + local isVisible = group ~= nil local listEntry = mainList:findById(tostring(i)) listEntry:setVisible(isVisible) if isVisible then - local group = pageState.stacks[basePageIndex + i] local nameText = listEntry:findById(GroupEntryID.NAME) local namePadding = listEntry:findById(GroupEntryID.PADDING)