PaperMC/paper-server/nms-patches/net/minecraft/core/RegistryMaterials.patch
CraftBukkit/Spigot 43702a9e10 Update to Minecraft 1.18-pre5
By: md_5 <git@md-5.net>
2021-11-22 09:00:00 +11:00

40 lines
1.2 KiB
Diff

--- a/net/minecraft/core/RegistryMaterials.java
+++ b/net/minecraft/core/RegistryMaterials.java
@@ -201,7 +201,7 @@
});
}
- return SystemUtils.getRandom(this.randomCache, random);
+ return (T) SystemUtils.getRandom(this.randomCache, random); // CraftBukkit - decompile error
}
@Override
@@ -228,7 +228,7 @@
return registrymaterials;
}, (registrymaterials) -> {
Builder<RegistryMaterials.a<T>> builder = ImmutableList.builder();
- Iterator iterator = registrymaterials.iterator();
+ Iterator<T> iterator = registrymaterials.iterator(); // CraftBukkit - decompile error
while (iterator.hasNext()) {
T t0 = iterator.next();
@@ -257,8 +257,10 @@
});
}
- private static final class a extends Record {
+ // CraftBukkit start
+ private static final record a<T>(ResourceKey<T> key, int id, T value) {
+ /*
private final ResourceKey<T> key;
private final int id;
private final T value;
@@ -292,5 +294,7 @@
public T value() {
return this.value;
}
+ */
+ // CraftBukkit end
}
}