From 8850f13ce0ce6654d48cfa5f54728d1683233d0d Mon Sep 17 00:00:00 2001 From: Gergely Polonkai Date: Tue, 9 Dec 2025 22:17:03 +0100 Subject: [PATCH] =?UTF-8?q?Make=20sure=20we=20call=20nodes=E2=80=99=20on?= =?UTF-8?q?=5Frightclick=20handler=20when=20holding=20an=20axe?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- functions.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/functions.lua b/functions.lua index fbb2138..713cfca 100644 --- a/functions.lua +++ b/functions.lua @@ -109,6 +109,16 @@ function stripped_tree.register_axes(mod_n, axe_types) -- TODO: Add wear to the axe, but it should depend on the material maybe? stripped_tree.maybe_strip_trunk(pos, user, itemstack) + + -- Taken from VoxelGarden + local node = core.get_node_or_nil(pos) + if not node then return end + + local node_def = core.registered_nodes[node.name] + + if node_def and node_def.on_rightclick then + return node_def.on_rightclick(pos, node, user, itemstack, pointed_thing) + end end, } )