Class Ingredient
java.lang.Object
net.minecraft.world.item.crafting.Ingredient
- Direct Known Subclasses:
AbstractIngredient
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final recordstatic interface -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec<Ingredient> static final com.mojang.serialization.Codec<Ingredient> static final StreamCodec<RegistryFriendlyByteBuf, 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> static final com.mojang.serialization.MapCodec<Ingredient> -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedIngredient(Stream<? extends Ingredient.Value> p_43907_) privateIngredient(Ingredient.Value[] p_301101_) -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanprivate static com.mojang.serialization.Codec<Ingredient> codec(boolean p_298496_) booleanstatic 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> booleantoString()
-
Field Details
-
INVALIDATION_COUNTER
-
EMPTY
-
CONTENTS_STREAM_CODEC
-
values
-
itemStacks
-
stackingIds
@Nullable private it.unimi.dsi.fastutil.ints.IntList stackingIds -
VANILLA_CODEC
The vanilla codec that doesn't support custom Ingredient types. -
VANILLA_MAP_CODEC
-
CODEC
-
VANILLA_CODEC_NONEMPTY
-
CODEC_NONEMPTY
-
invalidationCounter
private int invalidationCounter -
isVanilla
private final boolean isVanilla
-
-
Constructor Details
-
Ingredient
-
Ingredient
-
-
Method Details
-
invalidateAll
public static void invalidateAll() -
getItems
-
test
-
getStackingIds
public it.unimi.dsi.fastutil.ints.IntList getStackingIds() -
isEmpty
public boolean isEmpty() -
equals
-
fromValues
-
of
-
of
-
of
-
of
-
of
-
checkInvalidation
public final boolean checkInvalidation() -
markValid
protected final void markValid() -
invalidate
protected void invalidate() -
isSimple
public boolean isSimple() -
isVanilla
public final boolean isVanilla() -
serializer
-
toString
-
codec
-