Archived
0

добавлен WorldUnloadedException

This commit is contained in:
2018-08-16 13:25:05 +03:00
parent 252ebccf8c
commit b4f2b72e3a
3 changed files with 6 additions and 3 deletions

View File

@@ -47,8 +47,7 @@ public class SimpleChunk implements Chunk {
@Override @Override
public World getWorld() { public World getWorld() {
if (refWorld.get() == null) { if (refWorld.get() == null) {
log.error("World unloaded?"); throw new WorldUnloadedException();
return null;
} else { } else {
return refWorld.get(); return refWorld.get();
} }

View File

@@ -71,6 +71,6 @@ public class SimpleChunkSection implements ChunkSection {
@Override @Override
public World getWorld() { public World getWorld() {
return null; throw new UnsupportedOperationException();
} }
} }

View File

@@ -0,0 +1,4 @@
package mc.world.flat;
public class WorldUnloadedException extends RuntimeException {
}