Class ModelManager
java.lang.Object
net.minecraft.client.resources.model.ModelManager
- All Implemented Interfaces:
AutoCloseable,PreparableReloadListener
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
PreparableReloadListener.PreparationBarrier -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AtlasSetprivate Map<ModelResourceLocation, BakedModel> private final BlockColorsprivate final BlockModelShaperprivate static final org.slf4j.Loggerprivate intprivate BakedModelprivate ModelBakeryprivate it.unimi.dsi.fastutil.objects.Object2IntMap<BlockState> private static final Map<ResourceLocation, ResourceLocation> -
Constructor Summary
ConstructorsConstructorDescriptionModelManager(TextureManager pTextureManager, BlockColors pBlockColors, int pMaxMipmapLevels) -
Method Summary
Modifier and TypeMethodDescriptionprivate voidapply(ModelManager.ReloadState pReloadState, ProfilerFiller pProfiler) voidclose()getAtlas(ResourceLocation pLocation) getModel(ModelResourceLocation pModelLocation) private static CompletableFuture<Map<ResourceLocation, BlockModel>> loadBlockModels(ResourceManager pResourceManager, Executor pExecutor) private static CompletableFuture<Map<ResourceLocation, List<BlockStateModelLoader.LoadedJson>>> loadBlockStates(ResourceManager pResourceManager, Executor pExecutor) private ModelManager.ReloadStateloadModels(ProfilerFiller pProfilerFiller, Map<ResourceLocation, AtlasSet.StitchResult> pAtlasPreparations, ModelBakery pModelBakery) final CompletableFuture<Void> reload(PreparableReloadListener.PreparationBarrier pPreparationBarrier, ResourceManager pResourceManager, ProfilerFiller pPreparationsProfiler, ProfilerFiller pReloadProfiler, Executor pBackgroundExecutor, Executor pGameExecutor) booleanrequiresRender(BlockState pOldState, BlockState pNewState) voidupdateMaxMipLevel(int pLevel) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.server.packs.resources.PreparableReloadListener
getName
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
VANILLA_ATLASES
-
bakedRegistry
-
atlases
-
blockModelShaper
-
blockColors
-
maxMipmapLevels
private int maxMipmapLevels -
missingModel
-
modelGroups
-
modelBakery
-
-
Constructor Details
-
ModelManager
-
-
Method Details
-
getModel
-
getMissingModel
-
getBlockModelShaper
-
reload
public final CompletableFuture<Void> reload(PreparableReloadListener.PreparationBarrier pPreparationBarrier, ResourceManager pResourceManager, ProfilerFiller pPreparationsProfiler, ProfilerFiller pReloadProfiler, Executor pBackgroundExecutor, Executor pGameExecutor) - Specified by:
reloadin interfacePreparableReloadListener
-
loadBlockModels
private static CompletableFuture<Map<ResourceLocation,BlockModel>> loadBlockModels(ResourceManager pResourceManager, Executor pExecutor) -
loadBlockStates
private static CompletableFuture<Map<ResourceLocation,List<BlockStateModelLoader.LoadedJson>>> loadBlockStates(ResourceManager pResourceManager, Executor pExecutor) -
loadModels
private ModelManager.ReloadState loadModels(ProfilerFiller pProfilerFiller, Map<ResourceLocation, AtlasSet.StitchResult> pAtlasPreparations, ModelBakery pModelBakery) -
apply
-
requiresRender
-
getAtlas
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-
updateMaxMipLevel
public void updateMaxMipLevel(int pLevel) -
getModelBakery
-