Paper/nms-patches/Enchantment.patch

20 lines
845 B
Diff
Raw Normal View History

2015-02-26 23:41:06 +01:00
--- /home/matt/mc-dev-private//net/minecraft/server/Enchantment.java 2015-02-26 22:40:22.459608141 +0000
+++ src/main/java/net/minecraft/server/Enchantment.java 2015-02-26 22:40:22.459608141 +0000
@@ -8,6 +8,7 @@
public abstract class Enchantment {
+ // CraftBukkit - update CraftEnchant.getName(i) if this changes
private static final Enchantment[] byId = new Enchantment[256];
public static final Enchantment[] b;
2015-02-26 23:41:06 +01:00
private static final Map<MinecraftKey, Enchantment> E = Maps.newHashMap();
@@ -55,6 +56,8 @@
Enchantment.byId[i] = this;
Enchantment.E.put(minecraftkey, this);
}
2015-02-26 23:41:06 +01:00
+
+ org.bukkit.enchantments.Enchantment.registerEnchantment(new org.bukkit.craftbukkit.enchantments.CraftEnchantment(this)); // CraftBukkit
}
public static Enchantment getByName(String s) {