From e2d2dcf3379f0bf9ba4d291823f67f86ddf607b8 Mon Sep 17 00:00:00 2001 From: DanMB Date: Mon, 14 Mar 2022 09:47:57 -0700 Subject: [PATCH] f --- src/main/java/com/volmit/iris/util/data/HeightMap.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/volmit/iris/util/data/HeightMap.java b/src/main/java/com/volmit/iris/util/data/HeightMap.java index 3fb401cc6..5b0a78f08 100644 --- a/src/main/java/com/volmit/iris/util/data/HeightMap.java +++ b/src/main/java/com/volmit/iris/util/data/HeightMap.java @@ -21,18 +21,18 @@ package com.volmit.iris.util.data; import java.util.Arrays; public class HeightMap { - private final byte[] height; + private final int[] height; public HeightMap() { - height = new byte[256]; - Arrays.fill(height, Byte.MIN_VALUE); + height = new int[256]; + Arrays.fill(height, 0); } public void setHeight(int x, int z, int h) { - height[x * 16 + z] = (byte) (h + Byte.MIN_VALUE); + height[x * 16 + z] = (h); } public int getHeight(int x, int z) { - return height[x * 16 + z] - Byte.MIN_VALUE; + return height[x * 16 + z]; } }