@@ -1,6 +1,24 @@
|
||||
--- a/net/minecraft/server/Chunk.java
|
||||
+++ b/net/minecraft/server/Chunk.java
|
||||
@@ -95,8 +95,19 @@
|
||||
@@ -31,7 +31,7 @@
|
||||
private BiomeStorage d;
|
||||
private final Map<BlockPosition, NBTTagCompound> e;
|
||||
public boolean loaded;
|
||||
- public final World world;
|
||||
+ public final WorldServer world; // CraftBukkit - type
|
||||
public final Map<HeightMap.Type, HeightMap> heightMap;
|
||||
private final ChunkConverter i;
|
||||
public final Map<BlockPosition, TileEntity> tileEntities;
|
||||
@@ -65,7 +65,7 @@
|
||||
this.m = Maps.newHashMap();
|
||||
this.n = new ShortList[16];
|
||||
this.entitySlices = (EntitySlice[]) (new EntitySlice[16]);
|
||||
- this.world = world;
|
||||
+ this.world = (WorldServer) world; // CraftBukkit - type
|
||||
this.loc = chunkcoordintpair;
|
||||
this.i = chunkconverter;
|
||||
HeightMap.Type[] aheightmap_type = HeightMap.Type.values();
|
||||
@@ -96,8 +96,19 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,7 +38,7 @@
|
||||
public Chunk(World world, ProtoChunk protochunk) {
|
||||
this(world, protochunk.getPos(), protochunk.getBiomeIndex(), protochunk.p(), protochunk.n(), protochunk.o(), protochunk.getInhabitedTime(), protochunk.getSections(), (Consumer) null);
|
||||
Iterator iterator = protochunk.y().iterator();
|
||||
@@ -138,6 +149,7 @@
|
||||
@@ -139,6 +150,7 @@
|
||||
|
||||
this.b(protochunk.r());
|
||||
this.s = true;
|
||||
@@ -28,7 +46,7 @@
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -228,9 +240,16 @@
|
||||
@@ -229,9 +241,16 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,7 +63,7 @@
|
||||
int i = blockposition.getX() & 15;
|
||||
int j = blockposition.getY();
|
||||
int k = blockposition.getZ() & 15;
|
||||
@@ -282,7 +301,8 @@
|
||||
@@ -283,7 +302,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -55,7 +73,7 @@
|
||||
iblockdata.onPlace(this.world, blockposition, iblockdata1, flag);
|
||||
}
|
||||
|
||||
@@ -377,7 +397,12 @@
|
||||
@@ -378,7 +398,12 @@
|
||||
|
||||
@Nullable
|
||||
public TileEntity a(BlockPosition blockposition, Chunk.EnumTileEntityState chunk_enumtileentitystate) {
|
||||
@@ -69,8 +87,8 @@
|
||||
|
||||
if (tileentity == null) {
|
||||
NBTTagCompound nbttagcompound = (NBTTagCompound) this.e.remove(blockposition);
|
||||
@@ -423,6 +448,13 @@
|
||||
tileentity1.ab_();
|
||||
@@ -424,6 +449,13 @@
|
||||
tileentity1.an_();
|
||||
}
|
||||
|
||||
+ // CraftBukkit start
|
||||
@@ -83,7 +101,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
@@ -472,6 +504,50 @@
|
||||
@@ -473,6 +505,50 @@
|
||||
|
||||
}
|
||||
|
||||
@@ -134,7 +152,7 @@
|
||||
public void markDirty() {
|
||||
this.s = true;
|
||||
}
|
||||
@@ -525,7 +601,7 @@
|
||||
@@ -526,7 +602,7 @@
|
||||
Iterator iterator = this.entitySlices[k].a(Entity.class).iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
@@ -143,7 +161,7 @@
|
||||
|
||||
if ((entitytypes == null || entity.getEntityType() == entitytypes) && entity.getBoundingBox().c(axisalignedbb) && predicate.test(entity)) {
|
||||
list.add(entity);
|
||||
@@ -546,7 +622,7 @@
|
||||
@@ -547,7 +623,7 @@
|
||||
Iterator iterator = this.entitySlices[k].a(oclass).iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
@@ -152,7 +170,7 @@
|
||||
|
||||
if (t0.getBoundingBox().c(axisalignedbb) && (predicate == null || predicate.test(t0))) {
|
||||
list.add(t0);
|
||||
@@ -620,7 +696,7 @@
|
||||
@@ -621,7 +697,7 @@
|
||||
|
||||
@Override
|
||||
public boolean isNeedsSaving() {
|
||||
@@ -161,7 +179,7 @@
|
||||
}
|
||||
|
||||
public void d(boolean flag) {
|
||||
@@ -761,7 +837,7 @@
|
||||
@@ -763,7 +839,7 @@
|
||||
|
||||
public void B() {
|
||||
if (this.o instanceof ProtoChunkTickList) {
|
||||
@@ -170,7 +188,7 @@
|
||||
return this.getType(blockposition).getBlock();
|
||||
});
|
||||
this.o = TickListEmpty.b();
|
||||
@@ -771,7 +847,7 @@
|
||||
@@ -773,7 +849,7 @@
|
||||
}
|
||||
|
||||
if (this.p instanceof ProtoChunkTickList) {
|
||||
@@ -179,18 +197,18 @@
|
||||
return this.getFluid(blockposition).getType();
|
||||
});
|
||||
this.p = TickListEmpty.b();
|
||||
@@ -783,12 +859,12 @@
|
||||
@@ -785,12 +861,12 @@
|
||||
}
|
||||
|
||||
public void a(WorldServer worldserver) {
|
||||
- if (this.o == TickListEmpty.b()) {
|
||||
+ if (this.o == TickListEmpty.<Block>b()) { // CraftBukkit - decompile error
|
||||
this.o = new TickListChunk<>(IRegistry.BLOCK::getKey, worldserver.getBlockTickList().a(this.loc, true, false));
|
||||
this.o = new TickListChunk<>(IRegistry.BLOCK::getKey, worldserver.getBlockTickList().a(this.loc, true, false), worldserver.getTime());
|
||||
this.setNeedsSaving(true);
|
||||
}
|
||||
|
||||
- if (this.p == TickListEmpty.b()) {
|
||||
+ if (this.p == TickListEmpty.<FluidType>b()) { // CraftBukkit - decompile error
|
||||
this.p = new TickListChunk<>(IRegistry.FLUID::getKey, worldserver.getFluidTickList().a(this.loc, true, false));
|
||||
this.p = new TickListChunk<>(IRegistry.FLUID::getKey, worldserver.getFluidTickList().a(this.loc, true, false), worldserver.getTime());
|
||||
this.setNeedsSaving(true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user