3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-23 14:50:08 +01:00
Paper/nms-patches/BiomeStorage.patch
2019-12-18 08:00:00 +11:00

36 Zeilen
1.2 KiB
Diff

--- a/net/minecraft/server/BiomeStorage.java
+++ b/net/minecraft/server/BiomeStorage.java
@@ -88,7 +88,7 @@
int[] aint = new int[this.g.length];
for (int i = 0; i < this.g.length; ++i) {
- aint[i] = IRegistry.BIOME.a((Object) this.g[i]);
+ aint[i] = IRegistry.BIOME.a(this.g[i]); // CraftBukkit - decompile error
}
return aint;
@@ -101,7 +101,7 @@
for (int j = 0; j < i; ++j) {
BiomeBase biomebase = abiomebase[j];
- packetdataserializer.writeInt(IRegistry.BIOME.a((Object) biomebase));
+ packetdataserializer.writeInt(IRegistry.BIOME.a(biomebase)); // CraftBukkit - decompile error
}
}
@@ -118,4 +118,14 @@
return this.g[i1 << BiomeStorage.e + BiomeStorage.e | j1 << BiomeStorage.e | l];
}
+
+ // CraftBukkit start
+ public void setBiome(int i, int j, int k, BiomeBase biome) {
+ int l = i & BiomeStorage.b;
+ int i1 = MathHelper.clamp(j, 0, BiomeStorage.c);
+ int j1 = k & BiomeStorage.b;
+
+ this.g[i1 << BiomeStorage.e + BiomeStorage.e | j1 << BiomeStorage.e | l] = biome;
+ }
+ // CraftBukkit end
}