Fix off-by-one in async lighting neighbor loop
This commit is contained in:
parent
5ceee0e6e0
commit
f1652c14d8
|
@ -157,8 +157,8 @@ index b681a9f..8ee0cec 100644
|
|||
+ chunk.lightUpdateTime = chunk.world.getTime();
|
||||
+
|
||||
+ final List<Chunk> neighbors = new ArrayList<Chunk>();
|
||||
+ for (int cx = (x >> 4) - 1; cx < (x >> 4) + 1; ++cx) {
|
||||
+ for (int cz = (z >> 4) - 1; cz < (z >> 4) + 1; ++cz) {
|
||||
+ for (int cx = (x >> 4) - 1; cx <= (x >> 4) + 1; ++cx) {
|
||||
+ for (int cz = (z >> 4) - 1; cz <= (z >> 4) + 1; ++cz) {
|
||||
+ if (this.chunkProvider.isChunkLoaded(cx, cz)) {
|
||||
+ Chunk neighbor = this.getChunkAt(cx, cz);
|
||||
+ if (neighbor != chunk) {
|
||||
|
|
Loading…
Reference in New Issue