Readd fix to copied code
This commit is contained in:
parent
b45e8600c8
commit
7dbc4c15bb
2 changed files with 2 additions and 2 deletions
|
|
@ -86,7 +86,7 @@ public class AsyncChunkProvider118_2 {
|
||||||
public synchronized Supplier<NBTTagCompound> getLoadedChunk(CraftWorld world, int x, int z) {
|
public synchronized Supplier<NBTTagCompound> getLoadedChunk(CraftWorld world, int x, int z) {
|
||||||
if (!world.isChunkLoaded(x, z)) return () -> null;
|
if (!world.isChunkLoaded(x, z)) return () -> null;
|
||||||
Chunk c = world.getHandle().getChunkIfLoaded(x, z); //already safe async on vanilla
|
Chunk c = world.getHandle().getChunkIfLoaded(x, z); //already safe async on vanilla
|
||||||
if ((c == null) || c.o) return () -> null; // c.loaded
|
if ((c == null) || !c.o) return () -> null; // c.loaded
|
||||||
if (currTick != MinecraftServer.currentTick) {
|
if (currTick != MinecraftServer.currentTick) {
|
||||||
currTick = MinecraftServer.currentTick;
|
currTick = MinecraftServer.currentTick;
|
||||||
currChunks = 0;
|
currChunks = 0;
|
||||||
|
|
|
||||||
|
|
@ -85,7 +85,7 @@ public class AsyncChunkProvider119 {
|
||||||
public synchronized Supplier<NBTTagCompound> getLoadedChunk(CraftWorld world, int x, int z) {
|
public synchronized Supplier<NBTTagCompound> getLoadedChunk(CraftWorld world, int x, int z) {
|
||||||
if (!world.isChunkLoaded(x, z)) return () -> null;
|
if (!world.isChunkLoaded(x, z)) return () -> null;
|
||||||
Chunk c = world.getHandle().getChunkIfLoaded(x, z); //already safe async on vanilla
|
Chunk c = world.getHandle().getChunkIfLoaded(x, z); //already safe async on vanilla
|
||||||
if ((c == null) || c.o) return () -> null; // c.loaded
|
if ((c == null) || !c.o) return () -> null; // c.loaded
|
||||||
if (currTick != MinecraftServer.currentTick) {
|
if (currTick != MinecraftServer.currentTick) {
|
||||||
currTick = MinecraftServer.currentTick;
|
currTick = MinecraftServer.currentTick;
|
||||||
currChunks = 0;
|
currChunks = 0;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue