ForgePatch/patches/minecraft/net/minecraft/enchantment/EnumEnchantmentType.java.patch

18 lines
599 B
Diff

--- ../src-base/minecraft/net/minecraft/enchantment/EnumEnchantmentType.java
+++ ../src-work/minecraft/net/minecraft/enchantment/EnumEnchantmentType.java
@@ -100,5 +100,13 @@
{
}
- public abstract boolean func_77557_a(Item p_77557_1_);
+ private com.google.common.base.Predicate<Item> delegate = null;
+ private EnumEnchantmentType(com.google.common.base.Predicate<Item> delegate)
+ {
+ this.delegate = delegate;
+ }
+ public boolean func_77557_a(Item p_77557_1_)
+ {
+ return this.delegate == null ? false : this.delegate.apply(p_77557_1_);
+ }
}