Read module settings under the key their feature declares

The decoder reads a setting under its declared key, as the object of its options or,
for a feature with a root option, as exactly that option's value; a wrong shape fails
naming the key and the resource. The studio schema renders the root option's schema as
the key's one shape. Iris passes its own JSON fields per target to the module host so
no key can take one, and the pack validators and messages name the keys packs write
(decorators, importedStructures).
This commit is contained in:
piexel committed 2026-10-09 23:27:24 +02:00
1 parent 081f793696
commit b642b7f04e
15 files changed
+96 -47

No files matched your search

@@ -533,10 +533,10 @@ public final class IrisModdedChunkGenerator extends ChunkGenerator {
}
String remedy = integratedEnvironment()
? "enable 'Generate Structures' for this world; Iris requires it, then deny families through "
+ "iris:structure disabled or complete keys through iris:structure disabledExact"
+ "importedStructures.disabled or complete keys through importedStructures.disabledExact"
: "set generate-structures=true in server.properties, restart the server, "
+ "then deny families through iris:structure disabled or complete keys through "
+ "iris:structure disabledExact";
+ "then deny families through importedStructures.disabled or complete keys through "
+ "importedStructures.disabledExact";
throw new IllegalStateException("Iris generator '" + dimensionKey
+ "' cannot bind while generate-structures=false; " + remedy);
}
@@ -290,8 +290,8 @@ final class ModdedNativeStructureStage {
+ " because generate-structures=false disables them outside the pack. That flag is fixed when "
+ "the world is created (server.properties generate-structures, or the Generate Structures "
+ "toggle in singleplayer), so it cannot be changed for this world: create a new world with "
+ "structures enabled, then deny families through iris:structure disabled or complete keys "
+ "through iris:structure disabledExact");
+ "structures enabled, then deny families through importedStructures.disabled or complete keys "
+ "through importedStructures.disabledExact");
}
ChunkPos chunkPos = chunk.getPos();
SectionPos sectionPos = SectionPos.of(chunkPos, world.getMinSectionY());