From 489ef43458443bcf051ef93fbc48daa1c1ff8dbb Mon Sep 17 00:00:00 2001 From: cora Date: Mon, 14 Nov 2022 03:10:19 +0100 Subject: [PATCH] Don't transfer whole stacks --- mods/ITEMS/mcl_hoppers/init.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mods/ITEMS/mcl_hoppers/init.lua b/mods/ITEMS/mcl_hoppers/init.lua index aea6ebdcb..10f37afb4 100644 --- a/mods/ITEMS/mcl_hoppers/init.lua +++ b/mods/ITEMS/mcl_hoppers/init.lua @@ -362,12 +362,12 @@ local function hopper_pull_from_mc (mc_ent, dest_pos) mcl_log("stack max: " .. tostring(stack:get_stack_max())) if not stack:get_name() or stack:get_name() ~= "" then - if dest_inv:room_for_item("main", stack) then + if dest_inv:room_for_item("main", stack:peek_item()) then mcl_log("Room so unload") - dest_inv:add_item("main", stack) - inv:set_stack("main", i, ItemStack("")) + dest_inv:add_item("main", stack:take_item()) + inv:set_stack("main", i, stack) - -- Take one stack and stop until next time + -- Take one item and stop until next time return else mcl_log("no Room")