Archiviert
13
0
Dieses Repository wurde am 2024-12-25 archiviert. Du kannst Dateien ansehen und es klonen, aber nicht pushen oder Issues/Pull-Requests öffnen.
Paper-Old/nms-patches/Enchantment.patch

20 Zeilen
1.0 KiB
Diff

2015-05-25 12:37:24 +02:00
--- a/net/minecraft/server/Enchantment.java
+++ b/net/minecraft/server/Enchantment.java
2018-08-26 04:00:00 +02:00
@@ -154,10 +154,15 @@
2018-07-15 02:00:00 +02:00
a("channeling", new EnchantmentTridentChanneling(Enchantment.Rarity.VERY_RARE, new EnumItemSlot[] { EnumItemSlot.MAINHAND}));
a("mending", new EnchantmentMending(Enchantment.Rarity.RARE, EnumItemSlot.values()));
a("vanishing_curse", new EnchantmentVanishing(Enchantment.Rarity.VERY_RARE, EnumItemSlot.values()));
2016-02-29 22:32:46 +01:00
+ // CraftBukkit start
2018-08-26 04:00:00 +02:00
+ for (Object enchantment : IRegistry.ENCHANTMENT) {
2016-06-09 03:43:49 +02:00
+ org.bukkit.enchantments.Enchantment.registerEnchantment(new org.bukkit.craftbukkit.enchantments.CraftEnchantment((Enchantment) enchantment));
2016-02-29 22:32:46 +01:00
+ }
+ // CraftBukkit end
}
2018-07-15 02:00:00 +02:00
private static void a(String s, Enchantment enchantment) {
2018-08-26 04:00:00 +02:00
- IRegistry.ENCHANTMENT.a(new MinecraftKey(s), (Object) enchantment);
+ IRegistry.ENCHANTMENT.a(new MinecraftKey(s), enchantment); // CraftBukkit - decompile error
}
public static enum Rarity {