From b9f3e1bf542b48b3614f84ca6dd9e993cfdf2542 Mon Sep 17 00:00:00 2001 From: 1F616EMO~nya Date: Sun, 14 Jul 2024 17:50:23 +0800 Subject: [PATCH] Log inventory actions on battery holders (#106) --- nodes/node_battery_holder.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/nodes/node_battery_holder.lua b/nodes/node_battery_holder.lua index dd1131a..1d5a6c7 100644 --- a/nodes/node_battery_holder.lua +++ b/nodes/node_battery_holder.lua @@ -30,7 +30,7 @@ if not minetest.get_modpath("technic") then holder_groups.not_in_creative_inventory = 1 end -minetest.register_node("digtron:battery_holder", { +local def = { description = S("Digtron Battery Holder"), _doc_items_longdesc = digtron.doc.battery_holder_longdesc, _doc_items_usagehelp = digtron.doc.battery_holder_usagehelp, @@ -127,4 +127,8 @@ minetest.register_node("digtron:battery_holder", { after_place_node = (function() if minetest.get_modpath("pipeworks") then return pipeworks.after_place end end)(), after_dig_node = (function() if minetest.get_modpath("pipeworks")then return pipeworks.after_dig end end)() -}) +} + +default.set_inventory_action_loggers(def, "digtron battery holder") + +minetest.register_node("digtron:battery_holder", def)