Package com.petrolpark
Class PetrolparkRegistries
java.lang.Object
com.petrolpark.PetrolparkRegistries
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final net.minecraft.core.Registry<IAdvancedIngredientType<? super net.neoforged.neoforge.fluids.FluidStack>> static final net.minecraft.core.Registry<IAdvancedIngredientType<? super net.minecraft.world.item.ItemStack>> static final net.minecraft.core.Registry<Badge> static final net.minecraft.core.Registry<BogglePatternGeneratorType> static final net.minecraft.core.Registry<DecayProductType> static final net.minecraft.core.Registry<EntityRewardType> static final net.minecraft.core.Registry<IngredientRandomizerType> static final net.minecraft.core.Registry<LootEntityNumberProviderType> static final net.minecraft.core.Registry<LootItemStackNumberProviderType> static final net.minecraft.core.Registry<LootTeamNumberProviderType> static final net.minecraft.core.Registry<RewardGeneratorType> static final net.minecraft.core.Registry<RewardType> static final net.minecraft.core.Registry<IScratchBlock.Type<?>> static final net.minecraft.core.Registry<IScratchClass<?, ?>> static final net.minecraft.core.Registry<IScratchExpression.Type<?>> static final net.minecraft.core.Registry<ITeam.ProviderType> static final net.minecraft.core.Registry<TeamRewardType> static final net.minecraft.core.Registry<ITradeListingReference.Type> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.core.HolderLookup.Provider provider, net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> registryKey, OBJECT object) static <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.core.Registry<OBJECT> registry, OBJECT object) static <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> registryKey, OBJECT object) Fetch the Holder of the given object in the Registry with the given key.static <OBJECT> Optional<net.minecraft.core.Registry<OBJECT>> getRegistry(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> key) Fetch the (Datapack) Registry with the given key.holderGetOrThrow(net.minecraft.core.HolderLookup.Provider provider, net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> registryKey) static voidinit()static final voidonNewRegistries(net.neoforged.neoforge.registries.NewRegistryEvent event) static <T> net.minecraft.core.Registry<T> register(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> key, boolean hasIntrusiveHolders) static final net.minecraft.core.RegistryAccessOnly call during gameplay, not during world loading or before.static <T> net.minecraft.core.Registry<T> simple(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> key)
-
Field Details
-
DECAY_PRODUCT_TYPES
-
TEAM_PROVIDER_TYPES
-
BADGES
-
TRADE_LISTING_REFERENCE_TYPES
public static final net.minecraft.core.Registry<ITradeListingReference.Type> TRADE_LISTING_REFERENCE_TYPES -
SCRATCH_CLASSES
-
SCRATCH_BLOCK_TYPES
-
SCRATCH_EXPRESSION_TYPES
public static final net.minecraft.core.Registry<IScratchExpression.Type<?>> SCRATCH_EXPRESSION_TYPES -
LOOT_ITEM_STACK_NUMBER_PROVIDER_TYPES
public static final net.minecraft.core.Registry<LootItemStackNumberProviderType> LOOT_ITEM_STACK_NUMBER_PROVIDER_TYPES -
LOOT_ENTITY_NUMBER_PROVIDER_TYPES
public static final net.minecraft.core.Registry<LootEntityNumberProviderType> LOOT_ENTITY_NUMBER_PROVIDER_TYPES -
LOOT_TEAM_NUMBER_PROVIDER_TYPES
public static final net.minecraft.core.Registry<LootTeamNumberProviderType> LOOT_TEAM_NUMBER_PROVIDER_TYPES -
INGREDIENT_RANDOMIZER_TYPES
public static final net.minecraft.core.Registry<IngredientRandomizerType> INGREDIENT_RANDOMIZER_TYPES -
ADVANCED_ITEM_INGREDIENT_TYPES
public static final net.minecraft.core.Registry<IAdvancedIngredientType<? super net.minecraft.world.item.ItemStack>> ADVANCED_ITEM_INGREDIENT_TYPES -
ADVANCED_FLUID_INGREDIENT_TYPES
public static final net.minecraft.core.Registry<IAdvancedIngredientType<? super net.neoforged.neoforge.fluids.FluidStack>> ADVANCED_FLUID_INGREDIENT_TYPES -
REWARD_GENERATOR_TYPES
-
REWARD_TYPES
-
ENTITY_REWARD_TYPES
-
TEAM_REWARD_TYPES
-
BOGGLE_PATTERN_GENERATOR_TYPES
public static final net.minecraft.core.Registry<BogglePatternGeneratorType> BOGGLE_PATTERN_GENERATOR_TYPES
-
-
Constructor Details
-
PetrolparkRegistries
public PetrolparkRegistries()
-
-
Method Details
-
registryAccess
public static final net.minecraft.core.RegistryAccess registryAccess()Only call during gameplay, not during world loading or before. -
getRegistry
public static <OBJECT> Optional<net.minecraft.core.Registry<OBJECT>> getRegistry(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> key) Fetch the (Datapack) Registry with the given key. Only call during gameplay, not during world loading or before.- Type Parameters:
OBJECT- Type of objects in the Registry- Parameters:
key-
-
getHolder
public static <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> registryKey, OBJECT object) Fetch the Holder of the given object in the Registry with the given key. Only call during gameplay, not during world loading or before.- Type Parameters:
OBJECT- Type of objects in the Registry- See Also:
-
getHolder
public static <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.core.Registry<OBJECT> registry, OBJECT object) -
getHolder
public static <OBJECT> Optional<net.minecraft.core.Holder.Reference<OBJECT>> getHolder(net.minecraft.core.HolderLookup.Provider provider, net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<OBJECT>> registryKey, OBJECT object) -
holderGetOrThrow
-
simple
@Internal public static <T> net.minecraft.core.Registry<T> simple(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> key) -
register
@Internal public static <T> net.minecraft.core.Registry<T> register(net.minecraft.resources.ResourceKey<net.minecraft.core.Registry<T>> key, boolean hasIntrusiveHolders) -
onNewRegistries
public static final void onNewRegistries(net.neoforged.neoforge.registries.NewRegistryEvent event) -
init
@Internal public static void init()
-