summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorupsilon <upsilon@langg.net>2020-05-26 22:29:16 +0200
committerupsilon <upsilon@langg.net>2020-05-26 22:29:16 +0200
commited282b02989f19c776c807ea09a572f4844547ed (patch)
tree3cf60c084c7caa392ab18f0835238cbaef915fd7
parent5410ea74f28de489f7cea15dc5c6dadf16f4d2f3 (diff)
downloadpipeworks-ed282b02989f19c776c807ea09a572f4844547ed.tar
pipeworks-ed282b02989f19c776c807ea09a572f4844547ed.tar.gz
pipeworks-ed282b02989f19c776c807ea09a572f4844547ed.tar.bz2
pipeworks-ed282b02989f19c776c807ea09a572f4844547ed.tar.xz
pipeworks-ed282b02989f19c776c807ea09a572f4844547ed.zip
Prevent node breaker from digging all nodes
A small mistake in the code allowed the node breaker to dig any node using any tool, including hand.
-rw-r--r--wielder.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/wielder.lua b/wielder.lua
index 13f4398..a0fb472 100644
--- a/wielder.lua
+++ b/wielder.lua
@@ -40,7 +40,7 @@ local can_tool_dig_node = function(nodename, toolcaps, toolname)
-- but a player holding one can - the game seems to fall back to the hand.
-- fall back to checking the hand's properties if the tool isn't the correct one.
local hand_caps = minetest.registered_items[""].tool_capabilities
- diggable = minetest.get_dig_params(nodegroups, hand_caps)
+ diggable = minetest.get_dig_params(nodegroups, hand_caps).diggable
end
return diggable
end