mirror of
https://github.com/webbukkit/dynmap.git
synced 2024-11-28 05:05:16 +01:00
Try to load chunk if it is not (yet) available.
This commit is contained in:
parent
37b4d560b4
commit
c2d8df8e94
12
MapTile.java
12
MapTile.java
@ -82,9 +82,19 @@ public class MapTile {
|
|||||||
for(x=x1; x<x2; x+=16) {
|
for(x=x1; x<x2; x+=16) {
|
||||||
for(z=z1; z<z2; z+=16) {
|
for(z=z1; z<z2; z+=16) {
|
||||||
if(!s.isChunkLoaded(x, 0, z)) {
|
if(!s.isChunkLoaded(x, 0, z)) {
|
||||||
log.info("chunk not loaded: " + x + ", " + z + " for tile " + this.toString());
|
// Will try to load chunk.
|
||||||
|
//log.info("chunk not loaded: " + x + ", " + z + " for tile " + this.toString());
|
||||||
|
try {
|
||||||
|
s.loadChunk(x, 0, z);
|
||||||
|
} catch(Exception e) {
|
||||||
|
log.log(Level.SEVERE, "Caught exception from loadChunk!", e);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
if(!s.isChunkLoaded(x, 0, z)) {
|
||||||
|
log.info("Could not load chunk: " + x + ", " + z + " for tile " + this.toString());
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user