Class Ingredient
java.lang.Object
net.minecraft.world.item.crafting.Ingredient
- Direct Known Subclasses:
- AbstractIngredient
- 
Nested Class SummaryNested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordstatic interface
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<Ingredient>static final com.mojang.serialization.Codec<Ingredient>static final Ingredientprivate static final AtomicIntegerprivate intprivate final booleanprivate ItemStack[]private it.unimi.dsi.fastutil.ints.IntListprivate final Ingredient.Value[]static final com.mojang.serialization.Codec<Ingredient>The vanilla codec that doesn't support custom Ingredient types.private static final com.mojang.serialization.Codec<Ingredient>
- 
Constructor SummaryConstructorsModifierConstructorDescriptionprotectedIngredient(Stream<? extends Ingredient.Value> p_43907_) privateIngredient(Ingredient.Value[] p_301101_) 
- 
Method SummaryModifier and TypeMethodDescriptionfinal booleanprivate static com.mojang.serialization.Codec<Ingredient>codec(boolean p_298496_) booleanstatic IngredientfromNetwork(FriendlyByteBuf p_43941_) static IngredientfromValues(Stream<? extends Ingredient.Value> p_43939_) getItems()it.unimi.dsi.fastutil.ints.IntListprotected voidstatic voidbooleanisEmpty()booleanisSimple()final booleanprotected final voidstatic Ingredientof()static Ingredientstatic Ingredientstatic Ingredientstatic IngredientIIngredientSerializer<? extends Ingredient>booleancom.google.gson.JsonElementtoJson(boolean p_299391_) final voidtoNetwork(FriendlyByteBuf p_43924_) 
- 
Field Details- 
INVALIDATION_COUNTER
- 
EMPTY
- 
values
- 
itemStacks
- 
stackingIds@Nullable private it.unimi.dsi.fastutil.ints.IntList stackingIds
- 
VANILLA_CODECThe vanilla codec that doesn't support custom Ingredient types.
- 
CODEC
- 
VANILLA_CODEC_NONEMPTY
- 
CODEC_NONEMPTY
- 
invalidationCounterprivate int invalidationCounter
- 
isVanillaprivate final boolean isVanilla
 
- 
- 
Constructor Details- 
Ingredient
- 
Ingredient
 
- 
- 
Method Details- 
invalidateAllpublic static void invalidateAll()
- 
getItems
- 
test
- 
getStackingIdspublic it.unimi.dsi.fastutil.ints.IntList getStackingIds()
- 
toNetwork
- 
toJsonpublic com.google.gson.JsonElement toJson(boolean p_299391_) 
- 
isEmptypublic boolean isEmpty()
- 
equals
- 
checkInvalidationpublic final boolean checkInvalidation()
- 
markValidprotected final void markValid()
- 
invalidateprotected void invalidate()
- 
isSimplepublic boolean isSimple()
- 
isVanillapublic final boolean isVanilla()
- 
serializer
- 
fromValues
- 
of
- 
of
- 
of
- 
of
- 
of
- 
fromNetwork
- 
codec
 
-