diff --git a/nodes/node_battery_holder.lua b/nodes/node_battery_holder.lua index 697beea..456f9cc 100644 --- a/nodes/node_battery_holder.lua +++ b/nodes/node_battery_holder.lua @@ -63,13 +63,13 @@ minetest.register_node("digtron:battery_holder", { inv:set_size("batteries", 8*4) end, - -- Only allow RE batteries to be placed in the inventory + -- Allow all items with energy storage to be placed in the inventory allow_metadata_inventory_put = function(pos, listname, index, stack, player) if listname == "batteries" then local node_name = stack:get_name() - -- Only allow RE batteries from technic mod - if node_name == "technic:battery" then + -- Allow all items with energy storage from technic mod + if technic.power_tools[node_name] ~= nil then local meta = stack:get_metadata() local md = minetest.deserialize(meta) -- And specifically if they hold any charge @@ -122,4 +122,4 @@ 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)() -}) \ No newline at end of file +})