From 1263c43b5d83e21d4b14637c236447f6fcd80cba Mon Sep 17 00:00:00 2001 From: Sumyjkl Date: Sat, 6 Aug 2022 14:38:42 +1000 Subject: [PATCH] elytra and other non-combat armour don't take durability damage when the player is attacked --- mods/ITEMS/mcl_armor/damage.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mods/ITEMS/mcl_armor/damage.lua b/mods/ITEMS/mcl_armor/damage.lua index ed616397db..ad0db64bf3 100644 --- a/mods/ITEMS/mcl_armor/damage.lua +++ b/mods/ITEMS/mcl_armor/damage.lua @@ -33,7 +33,7 @@ mcl_damage.register_modifier(function(obj, damage, reason) local itemname = itemstack:get_name() local enchantments = mcl_enchanting.get_enchantments(itemstack) - if not flags.bypasses_armor then + if not flags.bypasses_armor and minetest.get_item_group(itemname, "non_combat_armor") == 0 then points = points + minetest.get_item_group(itemname, "mcl_armor_points") toughness = toughness + minetest.get_item_group(itemname, "mcl_armor_toughness")