World height shader should now be less abrupt.
This commit is contained in:
parent
925296f326
commit
60217e4672
@ -55,11 +55,9 @@ public class WorldHeightShader {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private int calculateTerrainHeight(int worldX, int worldZ) {
|
private int calculateTerrainHeight(int worldX, int worldZ) {
|
||||||
double islandValue = islandLocator.getWorldBlockValue(worldX, worldZ);
|
double islandValue = islandLocator.getWorldBlockValue(worldX, worldZ) + 1D;
|
||||||
if (islandValue >= 0) {
|
islandValue *= 100;
|
||||||
return seaLevel;
|
return (int) Math.min(63, islandValue);
|
||||||
}
|
|
||||||
return (int) Math.max((- islandValue) * seaLevel, minimumHeight);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private double getHeightModifier(int worldX, int worldZ) {
|
private double getHeightModifier(int worldX, int worldZ) {
|
||||||
|
Loading…
Reference in New Issue
Block a user