Class DataPackRegistriesHooks
java.lang.Object
net.neoforged.neoforge.registries.DataPackRegistriesHooks
-
Field Summary
Modifier and TypeFieldDescriptionprivate static final List
<RegistryDataLoader.RegistryData<?>> private static final List
<RegistryDataLoader.RegistryData<?>> private static final List
<RegistryDataLoader.RegistryData<?>> private static final Set
<ResourceKey<? extends Registry<?>>> private static final Set
<ResourceKey<? extends Registry<?>>> -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription(package private) static <T> void
static List
<RegistryDataLoader.RegistryData<?>> Returns An unmodifiable view of the list of datapack registries.static Stream
<RegistryDataLoader.RegistryData<?>> static Set
<ResourceKey<? extends Registry<?>>> Returns An unmodifiable view of the set of synced non-vanilla datapack registry IDs.static <T> RegistryDataLoader.RegistryData
<T> getSyncedRegistry
(ResourceKey<? extends Registry<T>> registry) static List
<RegistryDataLoader.RegistryData<?>>
-
Field Details
-
NETWORKABLE_REGISTRIES
-
DATA_PACK_REGISTRIES
-
DATA_PACK_REGISTRIES_VIEW
-
SYNCED_CUSTOM_REGISTRIES
-
SYNCED_CUSTOM_REGISTRIES_VIEW
-
-
Constructor Details
-
DataPackRegistriesHooks
private DataPackRegistriesHooks()
-
-
Method Details
-
grabNetworkableRegistries
public static List<RegistryDataLoader.RegistryData<?>> grabNetworkableRegistries(List<RegistryDataLoader.RegistryData<?>> list) -
addRegistryCodec
-
getDataPackRegistries
Returns An unmodifiable view of the list of datapack registries.. These registries are loaded from per-world datapacks on server startup.- Returns:
- An unmodifiable view of the list of datapack registries
-
getDataPackRegistriesWithDimensions
-
getSyncedCustomRegistries
Returns An unmodifiable view of the set of synced non-vanilla datapack registry IDs. Clients must have each of a server's synced datapack registries to be able to connect to that server; vanilla clients therefore cannot connect if this list is non-empty on the server.- Returns:
- An unmodifiable view of the set of synced non-vanilla datapack registry IDs
-
getSyncedRegistry
@Nullable @Internal public static <T> RegistryDataLoader.RegistryData<T> getSyncedRegistry(ResourceKey<? extends Registry<T>> registry)
-