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.Identifierstatic final net.minecraft.resources.Identifierstatic final net.minecraft.resources.Identifierstatic final net.minecraft.resources.Identifier -
Method Summary
Modifier and TypeMethodDescriptionbooleanTests if the condition has been met or not.Set<net.minecraft.resources.Identifier> getType()Gets the type of the condition.static <RT> com.mojang.serialization.MapCodec<RegistryContains<RT>> of(net.minecraft.resources.Identifier typeId, net.minecraft.core.Registry<RT> registry)
-
Field Details
-
BLOCK
public static final net.minecraft.resources.Identifier BLOCK -
ITEM
public static final net.minecraft.resources.Identifier ITEM -
ENTITY
public static final net.minecraft.resources.Identifier ENTITY -
BLOCK_ENTITY
public static final net.minecraft.resources.Identifier BLOCK_ENTITY
-
-
Method Details
-
of
public static <RT> com.mojang.serialization.MapCodec<RegistryContains<RT>> of(net.minecraft.resources.Identifier 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.
-