From bf9161cb29e014c79283eb7cbdb5331a3c6f89a7 Mon Sep 17 00:00:00 2001 From: Ludovic Marie <136255825+ludovic111@users.noreply.github.com> Date: Sat, 10 Oct 2026 07:33:13 +0200 Subject: [PATCH] Give the chunk oracle full feature flags, a difficulty and an entity id source Co-Authored-By: Claude Sonnet 5.5 --- .../parity/VanillaChunkGenerationOracle.java | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/mods/horizon/src/test/java/dev/horizonlab/parity/VanillaChunkGenerationOracle.java b/mods/horizon/src/test/java/dev/horizonlab/parity/VanillaChunkGenerationOracle.java index 825f6e3d2..9d474a932 100644 --- a/mods/horizon/src/test/java/dev/horizonlab/parity/VanillaChunkGenerationOracle.java +++ b/mods/horizon/src/test/java/dev/horizonlab/parity/VanillaChunkGenerationOracle.java @@ -77,6 +77,19 @@ public final class VanillaChunkGenerationOracle { super(null, null, null, null, null, null, false, 0L, null, false); } static long seed; + static int nextEntityId; + @Override + public int getNextEntityId() { + return nextEntityId++; + } + @Override + public float getMoonBrightness(final BlockPos pos) { + return 0.0F; + } + @Override + public long getOverworldClockTime() { + return 0L; + } static RegistryAccess access; static net.minecraft.world.level.dimension.DimensionType type; static StructureManager structures; @@ -101,7 +114,7 @@ public final class VanillaChunkGenerationOracle { } @Override public net.minecraft.world.flag.FeatureFlagSet enabledFeatures() { - return net.minecraft.world.flag.FeatureFlags.DEFAULT_FLAGS; // an empty set filters every block out of holderLookup, so jigsaw final states fail to parse + return net.minecraft.world.flag.FeatureFlags.DEFAULT_FLAGS; // with none enabled, holderLookup filters every block out and jigsaw final states fail to parse } @Override public RegistryAccess registryAccess() { @@ -138,6 +151,7 @@ public final class VanillaChunkGenerationOracle { if (type == int.class) return 0; if (type == boolean.class) return false; if (type == float.class) return 0f; + if (type == net.minecraft.world.Difficulty.class) return net.minecraft.world.Difficulty.NORMAL; if (type == double.class) return 0d; return null; });