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

Allow paper multicore to call without locking

This commit is contained in:
DanMB
2022-06-04 22:19:36 -07:00
parent 3b5bdcfb51
commit ce8cc2cf37
3 changed files with 4 additions and 5 deletions

View File

@@ -80,7 +80,7 @@ public class IrisBiomeActuator extends EngineAssignedActuator<Biome> {
try {
IrisBiomeCustom custom = ib.getCustomBiome(rng, x, 0, z);
Object biomeBase = INMS.get().getCustomBiomeBaseHolderFor(getDimension().getLoadKey() + ":" + custom.getId());
//
if(biomeBase == null || !injectBiome(h, x, 0, z, biomeBase)) {
throw new RuntimeException("Cant inject biome!");
}

View File

@@ -156,7 +156,6 @@ public class IrisTerrainNormalActuator extends EngineAssignedActuator<BlockData>
} else {
h.set(xf, i, zf, getComplex().getRockStream().get(realX, realZ));
}
}
}
}

View File

@@ -270,7 +270,7 @@ public class BukkitChunkGenerator extends ChunkGenerator implements PlatformChun
public @NotNull ChunkData generateChunkData(@NotNull World world, @NotNull Random ignored, int x, int z, @NotNull BiomeGrid biome) {
try {
getEngine(world);
loadLock.acquire();
//loadLock.acquire();
computeStudioGenerator();
TerrainChunk tc = TerrainChunk.create(world, biome);
this.world.bind(world);
@@ -285,10 +285,10 @@ public class BukkitChunkGenerator extends ChunkGenerator implements PlatformChun
ChunkData c = tc.getRaw();
Iris.debug("Generated " + x + " " + z);
loadLock.release();
//loadLock.release();
return c;
} catch(Throwable e) {
loadLock.release();
//loadLock.release();
Iris.error("======================================");
e.printStackTrace();
Iris.reportErrorChunk(x, z, e, "CHUNK");