Fix ta4 chest take_item bug

master
Joachim Stolberg 2021-05-16 20:01:41 +02:00
parent f79eb9f8ea
commit 6ea6933001
1 changed files with 0 additions and 7 deletions

View File

@ -354,24 +354,17 @@ techage.register_node({"techage:chest_ta4"}, {
return nil
end
print(1)
if item_name then
print(2)
if mem.filter[item_name] or not mem.chest_configured then
print(3)
local taken = inv:remove_item("main", {name = item_name, count = num})
if taken:get_count() > 0 then
print(4)
return taken
end
end
else -- no item given
print(5)
if mem.chest_configured then
print(6)
return mConf.take_item(pos, inv, "main", num, mem.filter["unconfigured"])
else
print(7)
return techage.get_items(pos, inv, "main", num)
end
end