9
0
mirror of https://github.com/VolmitSoftware/Iris.git synced 2025-12-25 18:19:14 +00:00

Terrain chunk fixes

This commit is contained in:
cyberpwn
2022-01-12 08:17:28 -05:00
parent f9e3d96673
commit b220db9d85

View File

@@ -81,8 +81,8 @@ public class MCATerrainChunk implements TerrainChunk {
int xx = (x + ox) & 15;
int zz = (z + oz) & 15;
if(y > 255 || y < 0) {
return;
if(y > getMaxHeight() || y < getMinHeight()) {
return;
}
if(blockData == null) {
@@ -98,8 +98,8 @@ public class MCATerrainChunk implements TerrainChunk {
y = getMaxHeight();
}
if(y < 0) {
y = 0;
if(y < getMinHeight()) {
y = getMinHeight();
}
return NBTWorld.getBlockData(mcaChunk.getBlockStateAt((x + ox) & 15, y, (z + oz) & 15));