Houston, we got a patch (#2731)
* Houston, we got a patch * is this the end of the beginning or the beginning of the end
This commit is contained in:
@@ -5,7 +5,7 @@ Subject: [PATCH] Prevent chunk loading from Fluid Flowing
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/FluidTypeFlowing.java b/src/main/java/net/minecraft/server/FluidTypeFlowing.java
|
||||
index 3e9433e283..4660b95389 100644
|
||||
index 3099a5e65..376dca188 100644
|
||||
--- a/src/main/java/net/minecraft/server/FluidTypeFlowing.java
|
||||
+++ b/src/main/java/net/minecraft/server/FluidTypeFlowing.java
|
||||
@@ -0,0 +0,0 @@ public abstract class FluidTypeFlowing extends FluidType {
|
||||
@@ -25,7 +25,7 @@ index 3e9433e283..4660b95389 100644
|
||||
- IBlockData iblockdata1 = iworldreader.getType(blockposition1);
|
||||
+ IBlockData iblockdata1 = iworldreader.getTypeIfLoaded(blockposition1); // Paper
|
||||
+ if (iblockdata1 == null) continue; // Paper
|
||||
Fluid fluid = iblockdata1.p();
|
||||
Fluid fluid = iblockdata1.getFluid();
|
||||
|
||||
if (fluid.getType().a((FluidType) this) && this.a(enumdirection, (IBlockAccess) iworldreader, blockposition, iblockdata, blockposition1, iblockdata1)) {
|
||||
@@ -0,0 +0,0 @@ public abstract class FluidTypeFlowing extends FluidType {
|
||||
@@ -42,11 +42,10 @@ index 3e9433e283..4660b95389 100644
|
||||
+ continue;
|
||||
+ }
|
||||
|
||||
- return Pair.of(iblockdata1, iblockdata1.p());
|
||||
- return Pair.of(iblockdata1, iblockdata1.getFluid());
|
||||
- });
|
||||
+ pair = Pair.of(iblockdatax, iblockdatax.p());
|
||||
+ pair = Pair.of(iblockdatax, iblockdatax.getFluid());
|
||||
+ short2objectmap.put(short0, pair);
|
||||
+
|
||||
+ }
|
||||
+ // Paper end
|
||||
IBlockData iblockdata1 = (IBlockData) pair.getFirst();
|
||||
@@ -59,7 +58,7 @@ index 3e9433e283..4660b95389 100644
|
||||
- Pair<IBlockData, Fluid> pair = (Pair) short2objectmap.computeIfAbsent(short0, (j) -> {
|
||||
- IBlockData iblockdata1 = iworldreader.getType(blockposition1);
|
||||
-
|
||||
- return Pair.of(iblockdata1, iblockdata1.p());
|
||||
- return Pair.of(iblockdata1, iblockdata1.getFluid());
|
||||
- });
|
||||
+ // Paper start
|
||||
+ Pair pair = (Pair) short2objectmap.get(short0);
|
||||
@@ -67,7 +66,7 @@ index 3e9433e283..4660b95389 100644
|
||||
+ IBlockData iblockdatax = iworldreader.getTypeIfLoaded(blockposition1);
|
||||
+ if (iblockdatax == null) continue;
|
||||
+
|
||||
+ pair = Pair.of(iblockdatax, iblockdatax.p());
|
||||
+ pair = Pair.of(iblockdatax, iblockdatax.getFluid());
|
||||
+ short2objectmap.put(short0, pair);
|
||||
+ }
|
||||
+ // Paper end
|
||||
|
||||
Reference in New Issue
Block a user