mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-22 19:07:44 +01:00
Config to remove curse of binding with weakness
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
--- a/net/minecraft/world/inventory/ArmorSlot.java
|
||||
+++ b/net/minecraft/world/inventory/ArmorSlot.java
|
||||
@@ -42,7 +_,7 @@
|
||||
@Override
|
||||
public boolean mayPickup(Player player) {
|
||||
ItemStack item = this.getItem();
|
||||
- return (item.isEmpty() || player.isCreative() || !EnchantmentHelper.has(item, EnchantmentEffectComponents.PREVENT_ARMOR_CHANGE))
|
||||
+ return (item.isEmpty() || player.isCreative() || (!EnchantmentHelper.has(item, EnchantmentEffectComponents.PREVENT_ARMOR_CHANGE) || player.level().purpurConfig.playerRemoveBindingWithWeakness && player.hasEffect(net.minecraft.world.effect.MobEffects.WEAKNESS))) // Purpur - Config to remove curse of binding with weakness
|
||||
&& super.mayPickup(player);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user