Skip to content

Commit

Permalink
Bump mobs_redo to its latest commit (#84)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and github-actions[bot] authored Feb 23, 2024
1 parent 8cde48a commit 019ab82
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion mobs_redo/api.lua
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ local use_vh1 = minetest.get_modpath("visual_harm_1ndicators")
-- Global
mobs = {
mod = "redo",
version = "20240201",
version = "20240220",
translate = S,
invis = minetest.global_exists("invisibility") and invisibility or {},
node_snow = minetest.registered_aliases["mapgen_snow"]
Expand Down Expand Up @@ -2870,6 +2870,11 @@ function mob_class:on_punch(hitter, tflp, tool_capabilities, dir, damage)
-- toolrank support
local wear = floor((punch_interval / 75) * 9000)

-- check for punch_attack_uses being 0 to negate wear
if tool_capabilities.punch_attack_uses == 0 then
wear = 0
end

if mobs.is_creative(hitter:get_player_name()) then
wear = tr and 1 or 0
end
Expand Down

0 comments on commit 019ab82

Please sign in to comment.