diff --git a/NCPCompat/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockCache.java b/NCPCompat/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockCache.java index 6e8532b3..bd4866d2 100644 --- a/NCPCompat/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockCache.java +++ b/NCPCompat/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockCache.java @@ -21,6 +21,8 @@ public abstract class BlockCache { /** Cached shape values. */ private final CoordMap boundsMap = new CoordMap(); + private int maxBlockY = 255; + // TODO: switch to nodes with all details on, store a working node ? // TODO: maybe make very fast access arrays for the ray tracing checks. @@ -128,5 +130,13 @@ public abstract class BlockCache { boundsMap.put(x, y, z, nBounds); return nBounds; } + + /** + * Get the maximal y coordinate a block can be at (non air). + * @return + */ + public int getMaxBlockY(){ + return maxBlockY; + } }