mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-04-06 07:46:08 +00:00
@@ -27,7 +27,6 @@ import com.volmit.iris.engine.data.cache.AtomicCache;
|
||||
import com.volmit.iris.engine.framework.Engine;
|
||||
import com.volmit.iris.engine.object.annotations.*;
|
||||
import com.volmit.iris.engine.object.block.IrisBlockDrops;
|
||||
import com.volmit.iris.engine.object.cave.IrisCavePlacer;
|
||||
import com.volmit.iris.engine.object.common.IRare;
|
||||
import com.volmit.iris.engine.object.decoration.IrisDecorator;
|
||||
import com.volmit.iris.engine.object.deposits.IrisDepositGenerator;
|
||||
@@ -75,10 +74,6 @@ public class IrisBiome extends IrisRegistrant implements IRare {
|
||||
@Desc("This is the human readable name for this biome. This can and should be different than the file name. This is not used for loading biomes in other objects.")
|
||||
private String name = "A Biome";
|
||||
|
||||
@Desc("Register caves to generate")
|
||||
@ArrayType(min = 1, type = IrisCavePlacer.class)
|
||||
private KList<IrisCavePlacer> caves = new KList<>();
|
||||
|
||||
@ArrayType(min = 1, type = IrisBiomeCustom.class)
|
||||
@Desc("If the biome type custom is defined, specify this")
|
||||
private KList<IrisBiomeCustom> customDerivitives;
|
||||
|
||||
@@ -32,8 +32,6 @@ import com.volmit.iris.engine.object.carve.IrisCarveLayer;
|
||||
import com.volmit.iris.engine.object.carve.IrisCaveFluid;
|
||||
import com.volmit.iris.engine.object.carve.IrisCaveLayer;
|
||||
import com.volmit.iris.engine.object.carve.IrisCaverns;
|
||||
import com.volmit.iris.engine.object.cave.IrisCave;
|
||||
import com.volmit.iris.engine.object.cave.IrisCavePlacer;
|
||||
import com.volmit.iris.engine.object.deposits.IrisDepositGenerator;
|
||||
import com.volmit.iris.engine.object.feature.IrisFeaturePositional;
|
||||
import com.volmit.iris.engine.object.feature.IrisFeaturePotential;
|
||||
@@ -177,6 +175,9 @@ public class IrisDimension extends IrisRegistrant {
|
||||
@Desc("The placement style of biomes")
|
||||
private IrisGeneratorStyle skylandBiomeStyle = NoiseStyle.CELLULAR_IRIS_DOUBLE.style();
|
||||
|
||||
@Desc("Generate caves or not.")
|
||||
private boolean caves = true;
|
||||
|
||||
@Desc("Instead of filling objects with air, fills them with cobweb so you can see them")
|
||||
private boolean debugSmartBore = false;
|
||||
|
||||
@@ -209,6 +210,9 @@ public class IrisDimension extends IrisRegistrant {
|
||||
@Desc("Add painted walls in post processing")
|
||||
private boolean postProcessingWalls = true;
|
||||
|
||||
@Desc("Use post processing for caves or not")
|
||||
private boolean postProcessCaves = true;
|
||||
|
||||
@Desc("The world environment")
|
||||
private Environment environment = Environment.NORMAL;
|
||||
|
||||
@@ -301,6 +305,10 @@ public class IrisDimension extends IrisRegistrant {
|
||||
@Desc("Overlay additional noise on top of the interoplated terrain.")
|
||||
private KList<IrisShapedGeneratorStyle> overlayNoise = new KList<>();
|
||||
|
||||
@ArrayType(min = 1, type = IrisCaveLayer.class)
|
||||
@Desc("Define cave layers")
|
||||
private KList<IrisCaveLayer> caveLayers = new KList<>();
|
||||
|
||||
@ArrayType(min = 1, type = IrisCarveLayer.class)
|
||||
@Desc("Define carve layers")
|
||||
private KList<IrisCarveLayer> carveLayers = new KList<>();
|
||||
@@ -322,10 +330,6 @@ public class IrisDimension extends IrisRegistrant {
|
||||
@Desc("Cartographer map trade overrides")
|
||||
private IrisVillagerOverride patchCartographers = new IrisVillagerOverride().setDisableTrade(false);
|
||||
|
||||
@Desc("Register caves to generate")
|
||||
@ArrayType(min = 1, type = IrisCavePlacer.class)
|
||||
private KList<IrisCavePlacer> caves = new KList<>();
|
||||
|
||||
private final transient AtomicCache<Position2> parallaxSize = new AtomicCache<>();
|
||||
private final transient AtomicCache<CNG> rockLayerGenerator = new AtomicCache<>();
|
||||
private final transient AtomicCache<CNG> fluidLayerGenerator = new AtomicCache<>();
|
||||
|
||||
@@ -22,6 +22,7 @@ import com.volmit.iris.Iris;
|
||||
import com.volmit.iris.engine.IrisComplex;
|
||||
import com.volmit.iris.engine.data.cache.AtomicCache;
|
||||
import com.volmit.iris.engine.framework.Engine;
|
||||
import com.volmit.iris.engine.modifier.IrisCaveModifier;
|
||||
import com.volmit.iris.engine.object.annotations.Desc;
|
||||
import com.volmit.iris.engine.object.annotations.MinNumber;
|
||||
import com.volmit.iris.engine.object.annotations.RegistryListResource;
|
||||
@@ -82,8 +83,23 @@ public class IrisEntitySpawn implements IRare {
|
||||
int h = gen.getHeight(x, z, true);
|
||||
int hf = gen.getHeight(x, z, false);
|
||||
Location l = switch (getReferenceSpawner().getGroup()) {
|
||||
case NORMAL, CAVE -> new Location(c.getWorld(), x, hf + 1, z);
|
||||
// TODO HANDLE CAVES
|
||||
case NORMAL -> new Location(c.getWorld(), x, hf + 1, z);
|
||||
case CAVE -> {
|
||||
IrisComplex comp = gen.getComplex();
|
||||
IrisBiome cave = comp.getCaveBiomeStream().get(x, z);
|
||||
KList<Location> r = new KList<>();
|
||||
if (cave != null) {
|
||||
for (CaveResult i : ((IrisCaveModifier) gen.getCaveModifier()).genCaves(x, z)) {
|
||||
if (i.getCeiling() >= gen.getHeight() || i.getFloor() < 0 || i.getCeiling() - 2 <= i.getFloor()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
r.add(new Location(c.getWorld(), x, i.getFloor(), z));
|
||||
}
|
||||
}
|
||||
|
||||
yield r.getRandom(rng);
|
||||
}
|
||||
|
||||
case UNDERWATER, BEACH -> new Location(c.getWorld(), x, rng.i(h + 1, hf), z);
|
||||
};
|
||||
|
||||
@@ -27,7 +27,6 @@ import com.volmit.iris.engine.object.annotations.*;
|
||||
import com.volmit.iris.engine.object.biome.InferredType;
|
||||
import com.volmit.iris.engine.object.biome.IrisBiome;
|
||||
import com.volmit.iris.engine.object.block.IrisBlockDrops;
|
||||
import com.volmit.iris.engine.object.cave.IrisCavePlacer;
|
||||
import com.volmit.iris.engine.object.common.IRare;
|
||||
import com.volmit.iris.engine.object.deposits.IrisDepositGenerator;
|
||||
import com.volmit.iris.engine.object.feature.IrisFeaturePotential;
|
||||
@@ -70,10 +69,6 @@ public class IrisRegion extends IrisRegistrant implements IRare {
|
||||
@Desc("The name of the region")
|
||||
private String name = "A Region";
|
||||
|
||||
@Desc("Register caves to generate")
|
||||
@ArrayType(min = 1, type = IrisCavePlacer.class)
|
||||
private KList<IrisCavePlacer> caves = new KList<>();
|
||||
|
||||
@ArrayType(min = 1, type = IrisJigsawStructurePlacement.class)
|
||||
@Desc("Jigsaw structures")
|
||||
private KList<IrisJigsawStructurePlacement> jigsawStructures = new KList<>();
|
||||
|
||||
Reference in New Issue
Block a user