World height shader should now be less abrupt.

This commit is contained in:
Harrison Deng 2020-04-26 15:03:34 -05:00
parent 925296f326
commit 60217e4672

View File

@ -55,11 +55,9 @@ public class WorldHeightShader {
}
private int calculateTerrainHeight(int worldX, int worldZ) {
double islandValue = islandLocator.getWorldBlockValue(worldX, worldZ);
if (islandValue >= 0) {
return seaLevel;
}
return (int) Math.max((- islandValue) * seaLevel, minimumHeight);
double islandValue = islandLocator.getWorldBlockValue(worldX, worldZ) + 1D;
islandValue *= 100;
return (int) Math.min(63, islandValue);
}
private double getHeightModifier(int worldX, int worldZ) {