diff --git a/common/src/main/java/com/seibel/distanthorizons/common/wrappers/worldGeneration/BatchGenerationEnvironment.java b/common/src/main/java/com/seibel/distanthorizons/common/wrappers/worldGeneration/BatchGenerationEnvironment.java index 538ff134f..fde658101 100644 --- a/common/src/main/java/com/seibel/distanthorizons/common/wrappers/worldGeneration/BatchGenerationEnvironment.java +++ b/common/src/main/java/com/seibel/distanthorizons/common/wrappers/worldGeneration/BatchGenerationEnvironment.java @@ -471,7 +471,20 @@ public final class BatchGenerationEnvironment extends AbstractBatchGenerationEnv // ArrayGridList's use relative positions and don't have a center position // so we need to use the offsetFinal to select the correct position DhChunkPos chunkPos = new DhChunkPos(relX + refPosX + xOffsetFinal, relZ + refPosZ + zOffsetFinal); - ChunkAccess chunk = regionChunks.get(relX, relZ); + + + ChunkAccess chunk; + if (genEvent.targetGenerationStep != EDhApiWorldGenerationStep.LIGHT) // TODO using something other than LIGHT would be good for clarity + { + // DH's world gen will be used + chunk = regionChunks.get(relX, relZ); + } + else + { + // use the internal server's world gen + // this will cause a lot of server lag, but is the most accurate world gen option + chunk = this.params.level.getChunk(chunkPos.getX(), chunkPos.getZ(), ChunkStatus.FULL, true); + } if (chunkWrappersByDhPos.containsKey(chunkPos)) { diff --git a/coreSubProjects b/coreSubProjects index d398b3bc0..04f0b454e 160000 --- a/coreSubProjects +++ b/coreSubProjects @@ -1 +1 @@ -Subproject commit d398b3bc04c0275a58cf121fe90a265ee0e4b592 +Subproject commit 04f0b454eb64f0c748e2177647666a8369eea9be