Class RegistryContains<T>
java.lang.Object
net.darkhax.bookshelf.common.impl.data.conditions.RegistryContains<T>
- All Implemented Interfaces:
ILoadCondition
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final net.minecraft.resources.ResourceLocationstatic final net.minecraft.resources.ResourceLocationstatic final net.minecraft.resources.ResourceLocationstatic final net.minecraft.resources.ResourceLocation -
Method Summary
Modifier and TypeMethodDescriptionbooleanTests if the condition has been met or not.Set<net.minecraft.resources.ResourceLocation> getType()Gets the type of the condition.static <RT> com.mojang.serialization.MapCodec<RegistryContains<RT>> of(net.minecraft.resources.ResourceLocation typeId, net.minecraft.core.Registry<RT> registry)
-
Field Details
-
BLOCK
public static final net.minecraft.resources.ResourceLocation BLOCK -
ITEM
public static final net.minecraft.resources.ResourceLocation ITEM -
ENTITY
public static final net.minecraft.resources.ResourceLocation ENTITY -
BLOCK_ENTITY
public static final net.minecraft.resources.ResourceLocation BLOCK_ENTITY
-
-
Method Details
-
of
public static <RT> com.mojang.serialization.MapCodec<RegistryContains<RT>> of(net.minecraft.resources.ResourceLocation typeId, net.minecraft.core.Registry<RT> registry) -
allowLoading
public boolean allowLoading()Description copied from interface:ILoadConditionTests if the condition has been met or not.- Specified by:
allowLoadingin interfaceILoadCondition- Returns:
- Has the condition been met?
-
getRequiredEntries
-
getType
Description copied from interface:ILoadConditionGets the type of the condition. This is required for serializing conditions.- Specified by:
getTypein interfaceILoadCondition- Returns:
- The type of the condition.
-