类 AbstractIngredient
java.lang.Object
net.minecraft.world.item.crafting.Ingredient
net.minecraftforge.common.crafting.AbstractIngredient
- 直接已知子类:
CompoundIngredient
,DifferenceIngredient
,IntersectionIngredient
,PartialNBTIngredient
,StrictNBTIngredient
Extension of
Ingredient
which makes most methods custom ingredients need to implement abstract, and removes the static constructors
Mods are encouraged to extend this class for their custom ingredients-
嵌套类概要
从类继承的嵌套类/接口 net.minecraft.world.item.crafting.Ingredient
Ingredient.ItemValue, Ingredient.TagValue, Ingredient.Value
-
字段概要
从类继承的字段 net.minecraft.world.item.crafting.Ingredient
EMPTY
-
构造器概要
构造器限定符构造器说明protected
Empty constructor, for the sake of dynamic ingredientsprotected
AbstractIngredient
(Stream<? extends Ingredient.Value> values) Value constructor, for ingredients that have some vanilla representation -
方法概要
修饰符和类型方法说明static Ingredient
fromJson
(@Nullable com.google.gson.JsonElement json) 已过时。static Ingredient
fromNetwork
(FriendlyByteBuf buffer) static Ingredient
fromValues
(Stream<? extends Ingredient.Value> values) 已过时。abstract IIngredientSerializer<? extends Ingredient>
abstract boolean
isSimple()
static Ingredient
of()
已过时。useIngredient.of()
static Ingredient
已过时。useIngredient.of(Stream)
(Stream)}static Ingredient
已过时。useIngredient.of(TagKey)
(Stream)}static Ingredient
已过时。useIngredient.of(ItemStack...)
(Stream)}static Ingredient
已过时。useIngredient.of(ItemLike...)
(Stream)}abstract com.google.gson.JsonElement
toJson()
从类继承的方法 net.minecraft.world.item.crafting.Ingredient
checkInvalidation, fromJson, getItems, getStackingIds, invalidate, invalidateAll, isEmpty, isVanilla, markValid, merge, test, toNetwork, valueFromJson
-
构造器详细资料
-
AbstractIngredient
protected AbstractIngredient()Empty constructor, for the sake of dynamic ingredients -
AbstractIngredient
Value constructor, for ingredients that have some vanilla representation
-
-
方法详细资料
-
isSimple
public abstract boolean isSimple()- 覆盖:
isSimple
在类中Ingredient
-
getSerializer
- 覆盖:
getSerializer
在类中Ingredient
-
toJson
public abstract com.google.gson.JsonElement toJson()- 覆盖:
toJson
在类中Ingredient
-
fromValues
已过时。 -
of
已过时。useIngredient.of()
-
of
已过时。useIngredient.of(ItemLike...)
(Stream)} -
of
已过时。useIngredient.of(ItemStack...)
(Stream)} -
of
已过时。useIngredient.of(Stream)
(Stream)} -
of
已过时。useIngredient.of(TagKey)
(Stream)} -
fromNetwork
-
fromJson
已过时。useIngredient.fromJson(JsonElement)
(Stream)}
-
Ingredient.fromJson(JsonElement)
(Stream)}