Interface ResourcePack

All Superinterfaces:
AutoCloseable
All Known Implementing Classes:
AbstractFileResourcePack, DefaultResourcePack, DirectoryResourcePack, ZipResourcePack

public interface ResourcePack extends AutoCloseable
A resource pack, providing resources to resource managers.

They are single-use in the lifecycle of a lifecycled resource manager. A ResourcePackProfile is a persistent representation of the resource packs, and can be used to recreate the packs on demand.

Mappings:
Namespace Name
official ais
intermediary net/minecraft/class_3262
named net/minecraft/resource/ResourcePack
  • Field Details

    • METADATA_PATH_SUFFIX

      static final String METADATA_PATH_SUFFIX
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official b Lais;b:Ljava/lang/String;
      intermediary field_29780 Lnet/minecraft/class_3262;field_29780:Ljava/lang/String;
      named METADATA_PATH_SUFFIX Lnet/minecraft/resource/ResourcePack;METADATA_PATH_SUFFIX:Ljava/lang/String;
    • PACK_METADATA_NAME

      static final String PACK_METADATA_NAME
      See Also:
      Mappings:
      Namespace Name Mixin selector
      official c Lais;c:Ljava/lang/String;
      intermediary field_29781 Lnet/minecraft/class_3262;field_29781:Ljava/lang/String;
      named PACK_METADATA_NAME Lnet/minecraft/resource/ResourcePack;PACK_METADATA_NAME:Ljava/lang/String;
  • Method Details

    • openRoot

      Mappings:
      Namespace Name Mixin selector
      official a Lais;a([Ljava/lang/String;)Lajw;
      intermediary method_14410 Lnet/minecraft/class_3262;method_14410([Ljava/lang/String;)Lnet/minecraft/class_7367;
      named openRoot Lnet/minecraft/resource/ResourcePack;openRoot([Ljava/lang/String;)Lnet/minecraft/resource/InputSupplier;
    • open

      Mappings:
      Namespace Name Mixin selector
      official a Lais;a(Lait;Lacf;)Lajw;
      intermediary method_14405 Lnet/minecraft/class_3262;method_14405(Lnet/minecraft/class_3264;Lnet/minecraft/class_2960;)Lnet/minecraft/class_7367;
      named open Lnet/minecraft/resource/ResourcePack;open(Lnet/minecraft/resource/ResourceType;Lnet/minecraft/util/Identifier;)Lnet/minecraft/resource/InputSupplier;
    • findResources

      void findResources(ResourceType type, String namespace, String prefix, ResourcePack.ResultConsumer consumer)
      Mappings:
      Namespace Name Mixin selector
      official a Lais;a(Lait;Ljava/lang/String;Ljava/lang/String;Lais$a;)V
      intermediary method_14408 Lnet/minecraft/class_3262;method_14408(Lnet/minecraft/class_3264;Ljava/lang/String;Ljava/lang/String;Lnet/minecraft/class_3262$class_7664;)V
      named findResources Lnet/minecraft/resource/ResourcePack;findResources(Lnet/minecraft/resource/ResourceType;Ljava/lang/String;Ljava/lang/String;Lnet/minecraft/resource/ResourcePack$ResultConsumer;)V
    • getNamespaces

      Set<String> getNamespaces(ResourceType type)
      Mappings:
      Namespace Name Mixin selector
      official a Lais;a(Lait;)Ljava/util/Set;
      intermediary method_14406 Lnet/minecraft/class_3262;method_14406(Lnet/minecraft/class_3264;)Ljava/util/Set;
      named getNamespaces Lnet/minecraft/resource/ResourcePack;getNamespaces(Lnet/minecraft/resource/ResourceType;)Ljava/util/Set;
    • parseMetadata

      @Nullable <T> T parseMetadata(ResourceMetadataReader<T> metaReader) throws IOException
      Throws:
      IOException
      Mappings:
      Namespace Name Mixin selector
      official a Lais;a(Laje;)Ljava/lang/Object;
      intermediary method_14407 Lnet/minecraft/class_3262;method_14407(Lnet/minecraft/class_3270;)Ljava/lang/Object;
      named parseMetadata Lnet/minecraft/resource/ResourcePack;parseMetadata(Lnet/minecraft/resource/metadata/ResourceMetadataReader;)Ljava/lang/Object;
    • getName

      String getName()
      Mappings:
      Namespace Name Mixin selector
      official a Lais;a()Ljava/lang/String;
      intermediary method_14409 Lnet/minecraft/class_3262;method_14409()Ljava/lang/String;
      named getName Lnet/minecraft/resource/ResourcePack;getName()Ljava/lang/String;
    • isAlwaysStable

      default boolean isAlwaysStable()
      Returns whether the dynamic registry entries from this pack are always "stable"/not experimental.
      Returns:
      whether the dynamic registry entries from this pack are always "stable"/not experimental
      Mappings:
      Namespace Name Mixin selector
      official b Lais;b()Z
      intermediary method_45178 Lnet/minecraft/class_3262;method_45178()Z
      named isAlwaysStable Lnet/minecraft/resource/ResourcePack;isAlwaysStable()Z
    • close

      void close()
      Specified by:
      close in interface AutoCloseable