Fix item group rendering

This commit is contained in:
Gabriel Tofvesson 2024-10-12 23:24:41 +02:00
parent 6777df634d
commit 22301dfe77

View File

@ -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)