Class StructureManager
java.lang.Object
net.minecraft.world.level.levelgen.structure.templatesystem.StructureManager
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.mojang.datafixers.DataFixerprivate final Pathprivate static final org.slf4j.Loggerprivate ResourceManagerprivate static final Stringprivate static final Stringprivate static final Stringprivate final Map<ResourceLocation,Optional<StructureTemplate>> -
Constructor Summary
ConstructorsConstructorDescriptionStructureManager(ResourceManager p_74332_, LevelStorageSource.LevelStorageAccess p_74333_, com.mojang.datafixers.DataFixer p_74334_) -
Method Summary
Modifier and TypeMethodDescriptionprivate PathcreateAndValidatePathToStructure(ResourceLocation p_74349_, String p_74350_) createPathToStructure(ResourceLocation p_74344_, String p_74345_) get(ResourceLocation p_163775_) getOrCreate(ResourceLocation p_74342_) private Optional<StructureTemplate>loadFromGenerated(ResourceLocation p_163779_) private Optional<StructureTemplate>loadFromResource(ResourceLocation p_163777_) voidonResourceManagerReload(ResourceManager p_74336_) private StructureTemplatereadStructure(InputStream p_74338_) readStructure(CompoundTag p_74340_) voidremove(ResourceLocation p_74354_) booleansave(ResourceLocation p_74352_)
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
STRUCTURE_DIRECTORY_NAME
- See Also:
-
STRUCTURE_FILE_EXTENSION
- See Also:
-
STRUCTURE_TEXT_FILE_EXTENSION
- See Also:
-
structureRepository
-
fixerUpper
private final com.mojang.datafixers.DataFixer fixerUpper -
resourceManager
-
generatedDir
-
-
Constructor Details
-
StructureManager
public StructureManager(ResourceManager p_74332_, LevelStorageSource.LevelStorageAccess p_74333_, com.mojang.datafixers.DataFixer p_74334_)
-
-
Method Details
-
getOrCreate
-
get
-
onResourceManagerReload
-
loadFromResource
-
loadFromGenerated
-
readStructure
- Throws:
IOException
-
readStructure
-
save
-
createPathToStructure
-
createAndValidatePathToStructure
-
remove
-