Skip to content

Commit f7e86b4

Browse files
committed
temporary workaround for minetest-mods#24
* backport minetest-mods@3b97763 * it try to fix the problem of minetest-mods#24
1 parent 1e46a2b commit f7e86b4

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

3d_armor/api.lua

+3
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,9 @@ armor.punch = function(self, player, hitter, time_from_last_punch, tool_capabili
340340
local groupcaps = tool_capabilities.groupcaps or {}
341341
local uses = 0
342342
damage = false
343+
if next(groupcaps) == nil then
344+
damage = true
345+
end
343346
for group, caps in pairs(groupcaps) do
344347
local maxlevel = caps.maxlevel or 0
345348
local diff = maxlevel - level

0 commit comments

Comments
 (0)