Package net.neoforged.neoforge.resource
Class ResourcePackLoader
java.lang.Object
net.neoforged.neoforge.resource.ResourcePackLoader
- 
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final org.apache.logging.log4j.Loggerstatic final Stringstatic final Stringprivate static Map<net.neoforged.neoforgespi.locating.IModFile,Pack.ResourcesSupplier> static final MetadataSectionType<PackMetadataSection> - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionstatic RepositorySourcebuildPackFinder(Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier> modResourcePacks, PackType packType) static Pack.ResourcesSuppliercreatePackForMod(net.neoforged.neoforgespi.language.IModFileInfo mf) private static voidstatic Optional<Pack.ResourcesSupplier>getPackFor(String modId) static <V> Comparator<Map.Entry<String,V>> static voidloadResourcePacks(PackRepository resourcePacks, Function<Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier>, RepositorySource> packFinder) private static Packprivate static voidpackFinder(Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier> modResourcePacks, Consumer<Pack> packAcceptor, PackType packType) private static Pack.InforeadInfo(PackType type, Pack.ResourcesSupplier resources, String id, Component title) static PackreadWithOptionalMeta(String id, Component title, boolean required, Pack.ResourcesSupplier resources, PackType type, Pack.Position position, PackSource source)  
- 
Field Details
- 
MOD_DATA_ID
- See Also:
 
 - 
MOD_RESOURCES_ID
- See Also:
 
 - 
modResourcePacks
private static Map<net.neoforged.neoforgespi.locating.IModFile,Pack.ResourcesSupplier> modResourcePacks - 
LOGGER
private static final org.apache.logging.log4j.Logger LOGGER - 
OPTIONAL_FORMAT
 
 - 
 - 
Constructor Details
- 
ResourcePackLoader
public ResourcePackLoader() 
 - 
 - 
Method Details
- 
getPackFor
 - 
loadResourcePacks
public static void loadResourcePacks(PackRepository resourcePacks, Function<Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier>, RepositorySource> packFinder)  - 
findResourcePacks
private static void findResourcePacks() - 
buildPackFinder
public static RepositorySource buildPackFinder(Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier> modResourcePacks, PackType packType)  - 
packFinder
private static void packFinder(Map<net.neoforged.neoforgespi.locating.IModFile, Pack.ResourcesSupplier> modResourcePacks, Consumer<Pack> packAcceptor, PackType packType)  - 
readWithOptionalMeta
public static Pack readWithOptionalMeta(String id, Component title, boolean required, Pack.ResourcesSupplier resources, PackType type, Pack.Position position, PackSource source) throws IOException - Throws:
 IOException
 - 
readInfo
private static Pack.Info readInfo(PackType type, Pack.ResourcesSupplier resources, String id, Component title) throws IOException - Throws:
 IOException
 - 
makePack
 - 
createPackForMod
public static Pack.ResourcesSupplier createPackForMod(net.neoforged.neoforgespi.language.IModFileInfo mf)  - 
getDataPackNames
 - 
getSorter
 
 -