Interface ICustomItemPredicate
- All Known Implementing Classes:
AdvancementTests.CustomNamePredicate
Interface that mods can use to define
ItemPredicate
s with custom matching logic.-
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.serialization.Codec<? extends ICustomItemPredicate>
codec()
Returns the codec for this predicate.default ItemPredicate
Convert to a vanillaItemPredicate
.
-
Method Details
-
codec
com.mojang.serialization.Codec<? extends ICustomItemPredicate> codec()Returns the codec for this predicate.The codec must be registered to
NeoForgeRegistries.ITEM_PREDICATE_SERIALIZERS
.- Returns:
- the codec for this predicate
-
toVanilla
Convert to a vanillaItemPredicate
.
-