Package net.minecraft.data.advancements
Class AdvancementProvider
java.lang.Object
net.minecraft.data.advancements.AdvancementProvider
- All Implemented Interfaces:
DataProvider
- Direct Known Subclasses:
DataGeneratorTest.Advancements
-
Field Summary
Modifier and TypeFieldDescriptionprotected ExistingFileHelper
private final DataGenerator
private static final com.google.gson.Gson
private static final org.slf4j.Logger
private final List<Consumer<Consumer<Advancement>>>
Fields inherited from interface net.minecraft.data.DataProvider
SHA1
-
Constructor Summary
ConstructorDescriptionAdvancementProvider
(DataGenerator p_123966_) Deprecated.AdvancementProvider
(DataGenerator generatorIn, ExistingFileHelper fileHelperIn) -
Method Summary
Modifier and TypeMethodDescriptionprivate static Path
createPath
(Path p_123971_, Advancement p_123972_) getName()
protected void
registerAdvancements
(Consumer<Advancement> consumer, ExistingFileHelper fileHelper) Override this method for registering and generating customAdvancement
s.void
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
GSON
private static final com.google.gson.Gson GSON -
generator
-
tabs
-
fileHelper
-
-
Constructor Details
-
AdvancementProvider
Deprecated. -
AdvancementProvider
-
-
Method Details
-
run
- Specified by:
run
in interfaceDataProvider
-
registerAdvancements
Override this method for registering and generating customAdvancement
s.
Just useAdvancement.Builder
to build your Advancements, you don't need an extra consumer like the vanilla classes.- Parameters:
consumer
- used for the register function fromAdvancement.Builder
fileHelper
- used for the register function fromAdvancement.Builder
-
createPath
-
getName
- Specified by:
getName
in interfaceDataProvider
-