mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-07-02 07:56:48 +00:00
Replace continent renderer with bridgeStream
This commit is contained in:
parent
131c4692bc
commit
23cd5c117b
@ -49,14 +49,13 @@ public class IrisRenderer {
|
||||
colorFunction = (x, z) -> renderer.getComplex().getCaveBiomeStream().get(x, z).getColor(renderer, currentType).getRGB();
|
||||
case HEIGHT ->
|
||||
colorFunction = (x, z) -> Color.getHSBColor(renderer.getComplex().getHeightStream().get(x, z).floatValue(), 100, 100).getRGB();
|
||||
case CONTINENT -> {
|
||||
double fluidHeight = renderer.getComplex().getFluidHeight();
|
||||
int deltaHeight = renderer.getMaxHeight() - renderer.getMinHeight();
|
||||
colorFunction = (x, z) -> {
|
||||
double h = renderer.getComplex().getHeightStream().get(x, z);
|
||||
return new Color((int) (h * 255d / deltaHeight), 128, h > fluidHeight ? 0 : 255).getRGB();
|
||||
};
|
||||
}
|
||||
case CONTINENT ->
|
||||
colorFunction = (x, z) -> (switch (renderer.getComplex().getBridgeStream().get(x, z)) {
|
||||
case SHORE -> Color.YELLOW;
|
||||
case LAND -> Color.GREEN;
|
||||
case SEA -> Color.BLUE;
|
||||
case CAVE -> Color.BLACK;
|
||||
}).getRGB();
|
||||
}
|
||||
|
||||
double x, z;
|
||||
|
Loading…
x
Reference in New Issue
Block a user