mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2025-07-19 02:36:59 +00:00
Fixes
This commit is contained in:
parent
7a7fee1d8a
commit
cfc8458841
22
.idea/workspace.xml
generated
22
.idea/workspace.xml
generated
@ -74,7 +74,7 @@
|
||||
<recent name="C:\Users\cyberpwn\Documents\development\workspace\Iris\src\main\java\com\volmit\iris\gen\v2\scaffold\hunk" />
|
||||
</key>
|
||||
</component>
|
||||
<component name="RunManager" selected="Maven.Iris Build">
|
||||
<component name="RunManager" selected="Maven.Iris Release">
|
||||
<configuration default="true" type="MavenRunConfiguration" factoryName="Maven">
|
||||
<MavenSettings>
|
||||
<option name="myGeneralSettings" />
|
||||
@ -147,22 +147,22 @@
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state x="485" y="234" key="#com.intellij.structuralsearch.plugin.ui.StructuralSearchDialog/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1603860057506" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.bottom" timestamp="1604241709027">
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.bottom" timestamp="1604243429163">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.bottom/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604241709027" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.center" timestamp="1604241709026">
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.bottom/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604243429163" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.center" timestamp="1604243429163">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.center/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604241709026" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.left" timestamp="1604241709026">
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.center/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604243429163" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.left" timestamp="1604243429163">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.left/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604241709026" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.right" timestamp="1604241709027">
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.left/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604243429163" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.right" timestamp="1604243429163">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.right/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604241709027" />
|
||||
<state width="1921" height="983" key="GridCell.Tab.0.right/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604243429163" />
|
||||
<state x="312" y="0" key="SettingsEditor" timestamp="1603947206451">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
@ -175,9 +175,9 @@
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state x="532" y="239" key="run.anything.popup/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1603859771295" />
|
||||
<state x="539" y="15" width="840" height="1034" key="search.everywhere.popup" timestamp="1604060078796">
|
||||
<state x="539" y="15" width="840" height="1034" key="search.everywhere.popup" timestamp="1604241752782">
|
||||
<screen x="0" y="0" width="1920" height="1050" />
|
||||
</state>
|
||||
<state x="539" y="15" width="840" height="1034" key="search.everywhere.popup/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604060078796" />
|
||||
<state x="539" y="15" width="840" height="1034" key="search.everywhere.popup/-1920.0.1920.1050/1920.0.1920.1050/0.0.1920.1050@0.0.1920.1050" timestamp="1604241752782" />
|
||||
</component>
|
||||
</project>
|
@ -59,6 +59,11 @@ public class GenLayerBiome extends GenLayer
|
||||
return null;
|
||||
}
|
||||
|
||||
if(!iris.getDimension().getFocusRegion().trim().isEmpty())
|
||||
{
|
||||
return iris.loadRegion(iris.getDimension().getFocusRegion());
|
||||
}
|
||||
|
||||
return regionGenerator.fitRarity(iris.getDimension().getAllRegions(iris), bx, bz);
|
||||
}
|
||||
|
||||
|
@ -239,6 +239,11 @@ public class IrisDimension extends IrisRegistrant
|
||||
@Desc("Keep this either undefined or empty. Setting any biome name into this will force iris to only generate the specified biome. Great for testing.")
|
||||
private String focus = "";
|
||||
|
||||
@RegistryListBiome
|
||||
@DontObfuscate
|
||||
@Desc("Keep this either undefined or empty. Setting any region name into this will force iris to only generate the specified region. Great for testing.")
|
||||
private String focusRegion = "";
|
||||
|
||||
@MinNumber(0.0001)
|
||||
@MaxNumber(512)
|
||||
@DontObfuscate
|
||||
|
@ -41,6 +41,10 @@ public class IrisGenerator extends IrisRegistrant
|
||||
@Desc("The opacity, essentially a multiplier on the output.")
|
||||
private double opacity = 1;
|
||||
|
||||
@DontObfuscate
|
||||
@Desc("Multiply the compsites instead of adding them")
|
||||
private boolean multiplicitive = false;
|
||||
|
||||
@MinNumber(0.001)
|
||||
@DontObfuscate
|
||||
@Desc("The size of the cell fractures")
|
||||
@ -252,15 +256,24 @@ public class IrisGenerator extends IrisRegistrant
|
||||
|
||||
int hc = (int) ((cliffHeightMin * 10) + 10 + cliffHeightMax * seed + offsetX + offsetZ);
|
||||
double h = 0;
|
||||
double tp = 0;
|
||||
double tp = multiplicitive ? 1 : 0;
|
||||
|
||||
for(IrisNoiseGenerator i : composite)
|
||||
{
|
||||
tp += i.getOpacity();
|
||||
h += i.getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom);
|
||||
if(multiplicitive)
|
||||
{
|
||||
tp *= i.getOpacity();
|
||||
h *= i.getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom);
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
tp += i.getOpacity();
|
||||
h += i.getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom);
|
||||
}
|
||||
}
|
||||
|
||||
double v = (h / tp) * opacity;
|
||||
double v = multiplicitive ? h * opacity : (h / tp) * opacity;
|
||||
|
||||
if(Double.isNaN(v))
|
||||
{
|
||||
|
@ -13,5 +13,10 @@ public abstract class GenLayer
|
||||
this.rng = rng;
|
||||
}
|
||||
|
||||
public GenLayer()
|
||||
{
|
||||
this(null, null);
|
||||
}
|
||||
|
||||
public abstract double generate(double x, double z);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user