Check length of the Y dimension of the array, not the x dimension, which will only be 16

This commit is contained in:
t00thpick1 2017-09-08 23:16:41 -04:00
parent 0e51983819
commit 028f87653a

View File

@ -54,7 +54,7 @@ public class PrimitiveChunkStore implements ChunkStore {
@Override @Override
public void setTrue(int x, int y, int z) { public void setTrue(int x, int y, int z) {
if (y >= store.length || y < 0) if (y >= store[0][0].length || y < 0)
return; return;
store[x][z][y] = true; store[x][z][y] = true;
dirty = true; dirty = true;
@ -62,7 +62,7 @@ public class PrimitiveChunkStore implements ChunkStore {
@Override @Override
public void setFalse(int x, int y, int z) { public void setFalse(int x, int y, int z) {
if (y >= store.length || y < 0) if (y >= store[0][0].length || y < 0)
return; return;
store[x][z][y] = false; store[x][z][y] = false;
dirty = true; dirty = true;