mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-23 18:55:14 +01:00
Imrpove chunk state handling
This commit is contained in:
parent
f1b1af399d
commit
965e2530ec
@ -21,6 +21,7 @@ import org.dynmap.utils.VisibilityLimit;
|
||||
import net.minecraft.server.v1_14_R1.Chunk;
|
||||
import net.minecraft.server.v1_14_R1.ChunkCoordIntPair;
|
||||
import net.minecraft.server.v1_14_R1.ChunkRegionLoader;
|
||||
import net.minecraft.server.v1_14_R1.ChunkStatus;
|
||||
import net.minecraft.server.v1_14_R1.DataBits;
|
||||
import net.minecraft.server.v1_14_R1.NBTTagCompound;
|
||||
import net.minecraft.server.v1_14_R1.NBTTagList;
|
||||
@ -301,7 +302,8 @@ public class MapChunkCache114_1 extends AbstractMapChunkCache {
|
||||
nbt = nbt.getCompound("Level");
|
||||
if (nbt != null) {
|
||||
String stat = nbt.getString("Status");
|
||||
if ((stat == null) || (stat.equals("full") == false)) {
|
||||
ChunkStatus cs = ChunkStatus.a(stat);
|
||||
if ((stat == null) || (!cs.b(ChunkStatus.LIGHT))) {
|
||||
nbt = null;
|
||||
}
|
||||
}
|
||||
|
@ -21,6 +21,7 @@ import org.dynmap.utils.VisibilityLimit;
|
||||
import net.minecraft.server.v1_14_R1.Chunk;
|
||||
import net.minecraft.server.v1_14_R1.ChunkCoordIntPair;
|
||||
import net.minecraft.server.v1_14_R1.ChunkRegionLoader;
|
||||
import net.minecraft.server.v1_14_R1.ChunkStatus;
|
||||
import net.minecraft.server.v1_14_R1.DataBits;
|
||||
import net.minecraft.server.v1_14_R1.NBTTagCompound;
|
||||
import net.minecraft.server.v1_14_R1.NBTTagList;
|
||||
@ -321,7 +322,8 @@ public class MapChunkCache114 extends AbstractMapChunkCache {
|
||||
nbt = nbt.getCompound("Level");
|
||||
if (nbt != null) {
|
||||
String stat = nbt.getString("Status");
|
||||
if ((stat == null) || (stat.equals("full") == false)) {
|
||||
ChunkStatus cs = ChunkStatus.a(stat);
|
||||
if ((stat == null) || (!cs.b(ChunkStatus.LIGHT))) {
|
||||
nbt = null;
|
||||
if ((stat == null) || stat.equals("") && DynmapCore.migrateChunks()) {
|
||||
Chunk c = cw.getHandle().getChunkAt(x, z);
|
||||
|
@ -23,6 +23,7 @@ import org.dynmap.utils.VisibilityLimit;
|
||||
import net.minecraft.server.v1_15_R1.Chunk;
|
||||
import net.minecraft.server.v1_15_R1.ChunkCoordIntPair;
|
||||
import net.minecraft.server.v1_15_R1.ChunkRegionLoader;
|
||||
import net.minecraft.server.v1_15_R1.ChunkStatus;
|
||||
import net.minecraft.server.v1_15_R1.DataBits;
|
||||
import net.minecraft.server.v1_15_R1.NBTTagCompound;
|
||||
import net.minecraft.server.v1_15_R1.NBTTagList;
|
||||
@ -317,7 +318,8 @@ public class MapChunkCache115 extends AbstractMapChunkCache {
|
||||
nbt = nbt.getCompound("Level");
|
||||
if (nbt != null) {
|
||||
String stat = nbt.getString("Status");
|
||||
if ((stat == null) || (stat.equals("full") == false)) {
|
||||
ChunkStatus cs = ChunkStatus.a(stat);
|
||||
if ((stat == null) || (!cs.b(ChunkStatus.LIGHT))) {
|
||||
nbt = null;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user