1
0
forked from xjboss/KCauldronX

Return empty chunk in case of null and come back indent for ProcessingQueue, sorry! :)

This commit is contained in:
Prototik 2015-10-22 01:45:44 +07:00
parent c9caa8c770
commit ad909f2788
2 changed files with 102 additions and 102 deletions

View File

@ -250,9 +250,9 @@
+ Chunk chunk = (Chunk) this.loadedChunkHashMap_KC.get(LongHash.toLong(p_73154_1_, p_73154_2_)); + Chunk chunk = (Chunk) this.loadedChunkHashMap_KC.get(LongHash.toLong(p_73154_1_, p_73154_2_));
+ chunk = chunk == null ? (shouldLoadChunk() ? this.loadChunk(p_73154_1_, p_73154_2_) : this.defaultEmptyChunk) : chunk; // Cauldron handle forge server tick events and load the chunk within 5 seconds of the world being loaded (for chunk loaders) + chunk = chunk == null ? (shouldLoadChunk() ? this.loadChunk(p_73154_1_, p_73154_2_) : this.defaultEmptyChunk) : chunk; // Cauldron handle forge server tick events and load the chunk within 5 seconds of the world being loaded (for chunk loaders)
+ +
+ if (chunk == this.defaultEmptyChunk || chunk == null) + if (chunk == defaultEmptyChunk || chunk == null)
+ { + {
+ return chunk; + return defaultEmptyChunk;
+ } + }
+ +
+ if ((p_73154_1_ != chunk.xPosition || p_73154_2_ != chunk.zPosition) && !worldObj.isProfilingWorld()) + if ((p_73154_1_ != chunk.xPosition || p_73154_2_ != chunk.zPosition) && !worldObj.isProfilingWorld())