summaryrefslogtreecommitdiffstats
path: root/nms-patches/World.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nms-patches/World.patch')
-rw-r--r--nms-patches/World.patch63
1 files changed, 41 insertions, 22 deletions
diff --git a/nms-patches/World.patch b/nms-patches/World.patch
index 921a5b9e..5993990b 100644
--- a/nms-patches/World.patch
+++ b/nms-patches/World.patch
@@ -341,7 +341,26 @@
this.c(entity);
}
-@@ -1068,6 +1291,11 @@
+@@ -872,6 +1095,9 @@
+ int l = MathHelper.f(axisalignedbb.e) + 1;
+ int i1 = MathHelper.floor(axisalignedbb.c) - 1;
+ int j1 = MathHelper.f(axisalignedbb.f) + 1;
++ // CraftBukkit start - filter out large ranges
++ com.google.common.base.Preconditions.checkArgument(j - i <= 32 && l - k <= 32 && j1 - i1 <= 32, "Filtered out large getCubes call %s,%s %s,%s %s,%s", i, j, k, l, i1, j1);
++ // CraftBukkit end
+ WorldBorder worldborder = this.getWorldBorder();
+ boolean flag1 = entity != null && entity.br();
+ boolean flag2 = entity != null && this.g(entity);
+@@ -974,7 +1200,7 @@
+ }
+
+ public boolean a(AxisAlignedBB axisalignedbb) {
+- return this.a((Entity) null, axisalignedbb, true, Lists.newArrayList());
++ return this.a((Entity) null, axisalignedbb, true, Lists.<AxisAlignedBB>newArrayList()); // CraftBukkit - decompile error
+ }
+
+ public int a(float f) {
+@@ -1044,6 +1270,11 @@
for (i = 0; i < this.j.size(); ++i) {
entity = (Entity) this.j.get(i);
@@ -353,7 +372,7 @@
try {
++entity.ticksLived;
-@@ -1116,8 +1344,10 @@
+@@ -1092,8 +1323,10 @@
CrashReportSystemDetails crashreportsystemdetails1;
CrashReport crashreport1;
@@ -366,7 +385,7 @@
Entity entity1 = entity.bB();
if (entity1 != null) {
-@@ -1150,7 +1380,7 @@
+@@ -1126,7 +1359,7 @@
this.getChunkAt(j, l).b(entity);
}
@@ -375,7 +394,7 @@
this.c(entity);
}
-@@ -1159,6 +1389,13 @@
+@@ -1135,6 +1368,13 @@
this.methodProfiler.c("blockEntities");
this.M = true;
@@ -389,7 +408,7 @@
Iterator iterator = this.tileEntityListTick.iterator();
while (iterator.hasNext()) {
-@@ -1169,7 +1406,7 @@
+@@ -1145,7 +1385,7 @@
if (this.isLoaded(blockposition) && this.N.a(blockposition)) {
try {
@@ -398,7 +417,7 @@
((ITickable) tileentity).F_();
this.methodProfiler.b();
} catch (Throwable throwable2) {
-@@ -1191,11 +1428,13 @@
+@@ -1167,11 +1407,13 @@
}
this.M = false;
@@ -412,7 +431,7 @@
this.methodProfiler.c("pendingBlockEntities");
if (!this.b.isEmpty()) {
-@@ -1203,9 +1442,11 @@
+@@ -1179,9 +1421,11 @@
TileEntity tileentity1 = (TileEntity) this.b.get(i1);
if (!tileentity1.y()) {
@@ -424,7 +443,7 @@
if (this.isLoaded(tileentity1.getPosition())) {
Chunk chunk = this.getChunkAtWorldCoords(tileentity1.getPosition());
-@@ -1213,6 +1454,12 @@
+@@ -1189,6 +1433,12 @@
chunk.a(tileentity1.getPosition(), tileentity1);
this.notify(tileentity1.getPosition(), iblockdata, iblockdata, 3);
@@ -437,7 +456,7 @@
}
}
}
-@@ -1267,7 +1514,10 @@
+@@ -1243,7 +1493,10 @@
int j = MathHelper.floor(entity.locZ);
boolean flag1 = true;
@@ -449,7 +468,7 @@
entity.M = entity.locX;
entity.N = entity.locY;
entity.O = entity.locZ;
-@@ -1571,11 +1821,18 @@
+@@ -1547,11 +1800,18 @@
}
}
@@ -468,7 +487,7 @@
TileEntity tileentity = null;
if (this.M) {
-@@ -1610,6 +1867,14 @@
+@@ -1586,6 +1846,14 @@
public void setTileEntity(BlockPosition blockposition, @Nullable TileEntity tileentity) {
if (!this.E(blockposition)) {
if (tileentity != null && !tileentity.y()) {
@@ -483,7 +502,7 @@
if (this.M) {
tileentity.setPosition(blockposition);
Iterator iterator = this.b.iterator();
-@@ -1769,6 +2034,14 @@
+@@ -1745,6 +2013,14 @@
}
this.o = MathHelper.a(this.o, 0.0F, 1.0F);
@@ -498,7 +517,7 @@
}
}
}
-@@ -1900,7 +2173,10 @@
+@@ -1876,7 +2152,10 @@
}
public boolean c(EnumSkyBlock enumskyblock, BlockPosition blockposition) {
@@ -510,7 +529,7 @@
return false;
} else {
int i = 0;
-@@ -2067,7 +2343,7 @@
+@@ -2043,7 +2322,7 @@
while (iterator.hasNext()) {
Entity entity = (Entity) iterator.next();
@@ -519,7 +538,7 @@
arraylist.add(entity);
}
}
-@@ -2082,7 +2358,7 @@
+@@ -2058,7 +2337,7 @@
while (iterator.hasNext()) {
Entity entity = (Entity) iterator.next();
@@ -528,7 +547,7 @@
arraylist.add(entity);
}
}
-@@ -2131,7 +2407,7 @@
+@@ -2107,7 +2386,7 @@
}
}
@@ -537,7 +556,7 @@
}
@Nullable
-@@ -2152,8 +2428,17 @@
+@@ -2128,8 +2407,17 @@
while (iterator.hasNext()) {
Entity entity = (Entity) iterator.next();
@@ -557,7 +576,7 @@
++i;
}
}
-@@ -2162,12 +2447,18 @@
+@@ -2138,12 +2426,18 @@
}
public void a(Collection<Entity> collection) {
@@ -577,7 +596,7 @@
this.b(entity);
}
-@@ -2181,7 +2472,13 @@
+@@ -2157,7 +2451,13 @@
IBlockData iblockdata = this.getType(blockposition);
AxisAlignedBB axisalignedbb = flag ? null : block.getBlockData().c(this, blockposition);
@@ -592,7 +611,7 @@
}
public int K() {
-@@ -2291,6 +2588,11 @@
+@@ -2267,6 +2567,11 @@
for (int i = 0; i < this.players.size(); ++i) {
EntityHuman entityhuman1 = (EntityHuman) this.players.get(i);
@@ -604,7 +623,7 @@
if (predicate.apply(entityhuman1)) {
double d5 = entityhuman1.d(d0, d1, d2);
-@@ -2459,6 +2761,16 @@
+@@ -2435,6 +2740,16 @@
public void everyoneSleeping() {}
@@ -621,7 +640,7 @@
public float h(float f) {
return (this.p + (this.q - this.p) * f) * this.j(f);
}
-@@ -2676,7 +2988,7 @@
+@@ -2652,7 +2967,7 @@
int l = j * 16 + 8 - blockposition.getZ();
boolean flag = true;