mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-04-21 07:30:30 +00:00
Merge pull request #876 from VolmitSoftware/Development
Changelog: Fixed Versioning compilation issues Forceblock nolonger Crashes Forceblock Works now (as intended, as far as we can tell)
This commit is contained in:
@@ -24,7 +24,7 @@ plugins {
|
|||||||
id "de.undercouch.download" version "5.0.1"
|
id "de.undercouch.download" version "5.0.1"
|
||||||
}
|
}
|
||||||
|
|
||||||
version '2.2.11-1.19.2' // Needs to be version specific
|
version '2.2.13-1.19.2' // Needs to be version specific
|
||||||
def nmsVersion = "1.19.2"
|
def nmsVersion = "1.19.2"
|
||||||
def apiVersion = '1.19'
|
def apiVersion = '1.19'
|
||||||
def spigotJarVersion = '1.19.1-R0.1-SNAPSHOT'
|
def spigotJarVersion = '1.19.1-R0.1-SNAPSHOT'
|
||||||
|
|||||||
@@ -387,8 +387,6 @@ public class Iris extends VolmitPlugin implements Listener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void enable() {
|
private void enable() {
|
||||||
IrisToolbelt.retainMantleDataForSlice(String.class.getCanonicalName());
|
|
||||||
IrisToolbelt.retainMantleDataForSlice(BlockData.class.getCanonicalName());
|
|
||||||
instance = this;
|
instance = this;
|
||||||
services = new KMap<>();
|
services = new KMap<>();
|
||||||
initialize("com.volmit.iris.core.service").forEach((i) -> services.put((Class<? extends IrisService>) i.getClass(), (IrisService) i));
|
initialize("com.volmit.iris.core.service").forEach((i) -> services.put((Class<? extends IrisService>) i.getClass(), (IrisService) i));
|
||||||
@@ -416,6 +414,8 @@ public class Iris extends VolmitPlugin implements Listener {
|
|||||||
splash();
|
splash();
|
||||||
autoStartStudio();
|
autoStartStudio();
|
||||||
checkForBukkitWorlds();
|
checkForBukkitWorlds();
|
||||||
|
IrisToolbelt.retainMantleDataForSlice(String.class.getCanonicalName());
|
||||||
|
IrisToolbelt.retainMantleDataForSlice(BlockData.class.getCanonicalName());
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -57,11 +57,14 @@ public class IrisSurfaceDecorator extends IrisEngineDecorator {
|
|||||||
bd = decorator.getBlockData100(biome, getRng(), realX, height, realZ, getData());
|
bd = decorator.getBlockData100(biome, getRng(), realX, height, realZ, getData());
|
||||||
|
|
||||||
if(!underwater) {
|
if(!underwater) {
|
||||||
if(!canGoOn(bd, bdx) && !decorator.isForcePlace()) {
|
if(!canGoOn(bd, bdx) && (!decorator.isForcePlace() && decorator.getForceBlock() == null) ) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(decorator.getForceBlock() != null)
|
||||||
|
data.set(x, height, z, fixFaces(decorator.getForceBlock().getBlockData(getData()), x, height, z));
|
||||||
|
|
||||||
if(bd instanceof Bisected) {
|
if(bd instanceof Bisected) {
|
||||||
bd = bd.clone();
|
bd = bd.clone();
|
||||||
((Bisected) bd).setHalf(Bisected.Half.TOP);
|
((Bisected) bd).setHalf(Bisected.Half.TOP);
|
||||||
@@ -74,9 +77,8 @@ public class IrisSurfaceDecorator extends IrisEngineDecorator {
|
|||||||
((Bisected) bd).setHalf(Bisected.Half.BOTTOM);
|
((Bisected) bd).setHalf(Bisected.Half.BOTTOM);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(decorator.getForceBlock() != null)
|
data.set(x, height + 1, z, fixFaces(bd, x, height + 1, z));
|
||||||
data.set(x, height, z, fixFaces(decorator.getForceBlock().getBlockData(getData()), x, height, z));
|
|
||||||
data.set(x, height + 1, z, fixFaces(bd, x, height, z));
|
|
||||||
} else {
|
} else {
|
||||||
if(height < getDimension().getFluidHeight()) {
|
if(height < getDimension().getFluidHeight()) {
|
||||||
max = getDimension().getFluidHeight();
|
max = getDimension().getFluidHeight();
|
||||||
|
|||||||
@@ -224,7 +224,7 @@ public class IrisPostModifier extends EngineAssignedModifier<BlockData> {
|
|||||||
if(B.isFoliage(b) || b.getMaterial().equals(Material.DEAD_BUSH)) {
|
if(B.isFoliage(b) || b.getMaterial().equals(Material.DEAD_BUSH)) {
|
||||||
Material onto = getPostBlock(x, h, z, currentPostX, currentPostZ, currentData).getMaterial();
|
Material onto = getPostBlock(x, h, z, currentPostX, currentPostZ, currentData).getMaterial();
|
||||||
|
|
||||||
if(!B.canPlaceOnto(b.getMaterial(), onto)) {
|
if(!B.canPlaceOnto(b.getMaterial(), onto) && !B.isDecorant(b)) {
|
||||||
setPostBlock(x, h + 1, z, AIR, currentPostX, currentPostZ, currentData);
|
setPostBlock(x, h + 1, z, AIR, currentPostX, currentPostZ, currentData);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -213,24 +213,24 @@ public class IrisGenerator extends IrisRegistrant {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int hc = (int) ((cliffHeightMin * 10) + 10 + cliffHeightMax * seed + offsetX + offsetZ);
|
int hc = (int) ((cliffHeightMin * 10) + 10 + cliffHeightMax * getSeed() + offsetX + offsetZ);
|
||||||
double h = multiplicitive ? 1 : 0;
|
double h = multiplicitive ? 1 : 0;
|
||||||
double tp = 0;
|
double tp = 0;
|
||||||
|
|
||||||
if(composite.size() == 1) {
|
if(composite.size() == 1) {
|
||||||
if(multiplicitive) {
|
if(multiplicitive) {
|
||||||
h *= composite.get(0).getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
h *= composite.get(0).getNoise(getSeed() + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
||||||
} else {
|
} else {
|
||||||
tp += composite.get(0).getOpacity();
|
tp += composite.get(0).getOpacity();
|
||||||
h += composite.get(0).getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
h += composite.get(0).getNoise(getSeed() + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
for(IrisNoiseGenerator i : composite) {
|
for(IrisNoiseGenerator i : composite) {
|
||||||
if(multiplicitive) {
|
if(multiplicitive) {
|
||||||
h *= i.getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
h *= i.getNoise(getSeed() + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
||||||
} else {
|
} else {
|
||||||
tp += i.getOpacity();
|
tp += i.getOpacity();
|
||||||
h += i.getNoise(seed + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
h += i.getNoise(getSeed() + superSeed + hc, (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -248,8 +248,8 @@ public class IrisGenerator extends IrisRegistrant {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public double cell(double rx, double rz, double v, double superSeed) {
|
public double cell(double rx, double rz, double v, double superSeed) {
|
||||||
getCellGenerator(seed + 46222).setShuffle(getCellFractureShuffle());
|
getCellGenerator(getSeed() + 46222).setShuffle(getCellFractureShuffle());
|
||||||
return getCellGenerator(seed + 46222).getDistance(rx / getCellFractureZoom(), rz / getCellFractureZoom()) > getCellPercentSize() ? (v * getCellFractureHeight()) : v;
|
return getCellGenerator(getSeed() + 46222).getDistance(rx / getCellFractureZoom(), rz / getCellFractureZoom()) > getCellPercentSize() ? (v * getCellFractureHeight()) : v;
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean hasCellCracks() {
|
private boolean hasCellCracks() {
|
||||||
@@ -257,8 +257,8 @@ public class IrisGenerator extends IrisRegistrant {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public double getCliffHeight(double rx, double rz, double superSeed) {
|
public double getCliffHeight(double rx, double rz, double superSeed) {
|
||||||
int hc = (int) ((cliffHeightMin * 10) + 10 + cliffHeightMax * seed + offsetX + offsetZ);
|
int hc = (int) ((cliffHeightMin * 10) + 10 + cliffHeightMax * getSeed() + offsetX + offsetZ);
|
||||||
double h = cliffHeightGenerator.getNoise((long) (seed + superSeed + hc), (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
double h = cliffHeightGenerator.getNoise((long) (getSeed() + superSeed + hc), (rx + offsetX) / zoom, (rz + offsetZ) / zoom, getLoader());
|
||||||
return IrisInterpolation.lerp(cliffHeightMin, cliffHeightMax, h);
|
return IrisInterpolation.lerp(cliffHeightMin, cliffHeightMax, h);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user