From c9ac64d6c5e7952aadf254abffd9cf9c5c5fac5c Mon Sep 17 00:00:00 2001 From: Gabriel Tofvesson Date: Thu, 15 May 2025 02:34:20 +0200 Subject: [PATCH] Track newly non-blank stacks for targets of transfers --- localchest.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/localchest.lua b/localchest.lua index 01b5d68..397c928 100644 --- a/localchest.lua +++ b/localchest.lua @@ -77,7 +77,12 @@ function prototype:moveItemsTo(count, fromSlot, otherChest, toSlot) if myStack.count == 0 then self.slots[fromSlot] = nil end + targetStack.count = targetStack.count + tx + if targetStack:isBlank() then + targetStack.item = myStack.item + otherChest.slots[toSlot] = targetStack + end return tx end