1
0
Fork 0

Undo mesecon.register_mvps_dropper() and use abms until more research can be done.

This commit is contained in:
Michieal 2023-02-08 23:03:17 -05:00 committed by Gitea
parent 6c0525f00e
commit 1558c852d8
2 changed files with 26 additions and 11 deletions

View File

@ -69,6 +69,7 @@ local BAMBOO_ENDCAP_NAME = "mcl_bamboo:bamboo_endcap"
-- For when I learn more about the pistons...
function mcl_bamboo.break_orphaned(pos)
mcl_bamboo.mcl_log("Break_Orphaned called.")
local node_below = minetest.get_node(vector.offset(pos, 0, -1, 0))
local node_name = node_below.name

View File

@ -35,13 +35,27 @@ minetest.register_abm({
end,
})
--[[ TODO: Figure out how to make this work:
local function dropper_call(node, pushdir, stack, stackid)
mcl_bamboo.mcl_log("mvps_dropper call for bamboo:")
-- mcl_bamboo.break_orphaned()
mcl_bamboo.mcl_log(dump(node))
end
if minetest.get_modpath("mesecons_mvps") then
if mesecons_mvps then
if mesecon then
mcl_bamboo.mcl_log("registering mvps_dropper for bamboo:")
for x = 1, #mcl_bamboo.bamboo_index do
mesecon.register_mvps_dropper(mcl_bamboo.bamboo_index[x], mcl_bamboo.break_orphaned)
mesecon.register_mvps_dropper(mcl_bamboo.bamboo_index[x],dropper_call)
mcl_bamboo.mcl_log("registering: " .. mcl_bamboo.bamboo_index[x])
end
end
else
end
--]]
minetest.register_abm({
label = "Break Orphaned Bamboo",
nodenames = mcl_bamboo.bamboo_index,
@ -51,7 +65,7 @@ else
mcl_bamboo.break_orphaned(pos)
end,
})
end
-- Base Aliases.
local SCAFFOLDING_NAME = "mcl_bamboo:scaffolding"