From 34ae29e899da6dd700ab590a729c8726ae07db30 Mon Sep 17 00:00:00 2001 From: crabman77 Date: Sat, 18 Jul 2015 15:58:20 +0200 Subject: [PATCH] Remove our fix and replace with better Tenplus1's fix --- mods/mobs/api.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/mobs/api.lua b/mods/mobs/api.lua index fabed9f7..17c03791 100755 --- a/mods/mobs/api.lua +++ b/mods/mobs/api.lua @@ -1130,8 +1130,8 @@ end on_punch = function(self, hitter, tflp, tool_capabilities, dir) -- weapon wear local weapon = hitter:get_wielded_item() - if weapon:get_definition().tool_capabilities ~= nil and weapon:get_definition().tool_capabilities.full_punch_interval ~= nil then - local wear = ( weapon:get_definition().tool_capabilities.full_punch_interval / 75 ) * 9000 + if weapon:get_definition().tool_capabilities ~= nil then + local wear = ( (weapon:get_definition().tool_capabilities.full_punch_interval or 1.4) / 75 ) * 9000 weapon:add_wear(wear) hitter:set_wielded_item(weapon) end