forked from MineClone5/MineClone5
Make sideways hoppers try pushing down before sideways
This is consistent with its behaviour in Minecraft.
This commit is contained in:
parent
7be9a8a574
commit
eee07f56b5
|
@ -453,6 +453,11 @@ minetest.register_abm({
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- Try to move an item below before moving it sideways
|
||||||
|
local downnode = minetest.get_node(downpos)
|
||||||
|
if not minetest.registered_nodes[downnode.name] then return end
|
||||||
|
if mcl_util.move_item_container(pos, downpos) then return end
|
||||||
|
|
||||||
-- Move an item from the hopper into the container to which the hopper points to
|
-- Move an item from the hopper into the container to which the hopper points to
|
||||||
local g = minetest.registered_nodes[frontnode.name].groups.container
|
local g = minetest.registered_nodes[frontnode.name].groups.container
|
||||||
if g == 2 or g == 3 or g == 5 or g == 6 then
|
if g == 2 or g == 3 or g == 5 or g == 6 then
|
||||||
|
|
Loading…
Reference in New Issue