9
0
mirror of https://github.com/VolmitSoftware/Iris.git synced 2025-12-26 02:29:14 +00:00

Added forceBlock field for surface decorator.

This commit is contained in:
Vatuu
2022-07-22 02:18:37 +02:00
parent 637b90ad62
commit 386997f646
2 changed files with 5 additions and 2 deletions

View File

@@ -55,7 +55,7 @@ public class IrisSurfaceDecorator extends IrisEngineDecorator {
bd = decorator.getBlockData100(biome, getRng(), realX, height, realZ, getData());
if(!underwater) {
if(!canGoOn(bd, bdx)) {
if(!canGoOn(bd, bdx) && !decorator.isForcePlace()) {
return;
}
}
@@ -72,8 +72,9 @@ public class IrisSurfaceDecorator extends IrisEngineDecorator {
((Bisected) bd).setHalf(Bisected.Half.BOTTOM);
}
if(decorator.getForceBlock() != null)
data.set(x, height, z, decorator.getForceBlock().getBlockData(getData()));
data.set(x, height + 1, z, bd);
} else {
if(height < getDimension().getFluidHeight()) {
max = getDimension().getFluidHeight();

View File

@@ -53,6 +53,8 @@ public class IrisDecorator {
private IrisGeneratorStyle variance = NoiseStyle.STATIC.style();
@Desc("Forcefully place this decorant anywhere it is supposed to go even if it should not go on a specific surface block. For example, you could force tallgrass to place on top of stone by using this.")
private boolean forcePlace = false;
@Desc("Forced the surface block of this decorant to be the specified block. Assumes forcePlace.")
private IrisBlockData forceBlock;
@DependsOn({"scaleStack", "stackMin", "stackMax"})
@Desc("If stackMax is set to true, use this to limit its max height for large caverns")
private int absoluteMaxStack = 30;