mirror of
https://github.com/VolmitSoftware/Iris.git
synced 2026-11-28 00:34:19 +00:00
Contain failed placements and let engine failures end the chunk
Placement code caught Throwable and logged it, so a closed session, a stopping executor or an OOM inside a placement left a half-built chunk that was then persisted. A classifier in the api separates those failures from content failures: the first are rethrown, the second are skipped with one rate-limited warning per kind, subject and failure type. Upstream:54f3595baebe4aa1e47b38f7584f4f7e92a48cf9e01d9
This commit is contained in:
1 parent
fc5c6ce0ab
commit
de1c6e887f
13 files changed
+318
-22
No files matched your search
@@ -26,6 +26,7 @@ import art.arcane.volmlib.util.math.RNG;
|
||||
import com.volmit.ModuleLog;
|
||||
import com.volmit.block.BlockState;
|
||||
import com.volmit.config.FeatureSettings;
|
||||
import com.volmit.generation.GenerationFailures;
|
||||
import com.volmit.noise.NoiseFactory;
|
||||
import com.volmit.resource.ResourceId;
|
||||
import com.volmit.world.PackWorld;
|
||||
@@ -301,7 +302,7 @@ public final class BiomeLayers {
|
||||
try {
|
||||
blocks.add(layer.get(random, index + j, (wx + j) / blocksPerSample, j, (wz - j) / blocksPerSample));
|
||||
} catch (Throwable e) {
|
||||
log.error("A biome layer failed to pick a block", e);
|
||||
GenerationFailures.skipPlacement(log, e, "layer block", "biome layer " + index, "at " + (long) wx + "," + (long) wz + " depth " + j);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user