From 7e3dd715af7bf7a5781a08234cbcd0c82a5294ad Mon Sep 17 00:00:00 2001 From: kay27 Date: Fri, 30 Apr 2021 16:51:34 +0400 Subject: [PATCH] Fix https://git.minetest.land/MineClone2/MineClone2/issues/1681 by @cora --- mods/HUD/mcl_experience/init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/HUD/mcl_experience/init.lua b/mods/HUD/mcl_experience/init.lua index 47db77bca..fd78534fc 100644 --- a/mods/HUD/mcl_experience/init.lua +++ b/mods/HUD/mcl_experience/init.lua @@ -263,7 +263,7 @@ function mcl_experience.add_experience(player, experience) local can = final_candidates[math.random(#final_candidates)] local stack, list, index, wear = can.stack, can.list, can.index, can.wear local unbreaking_level = mcl_enchanting.get_enchantment(stack, "unbreaking") - local uses = mcl_util.calculate_durability(itemstack) + local uses = mcl_util.calculate_durability(stack) local multiplier = 2 * 65535 / uses local repair = experience * multiplier local new_wear = wear - repair