构造器和说明 |
---|
ShapedRecipe(ItemStack result)
已过时。
|
ShapedRecipe(NamespacedKey key,
ItemStack result)
Create a shaped recipe to craft the specified ItemStack.
|
限定符和类型 | 方法和说明 |
---|---|
java.util.Map<java.lang.Character,ItemStack> |
getIngredientMap()
Get a copy of the ingredients map.
|
NamespacedKey |
getKey()
Return the namespaced identifier for this object.
|
ItemStack |
getResult()
Get the result.
|
java.lang.String[] |
getShape()
Get the shape.
|
ShapedRecipe |
setIngredient(char key,
Material ingredient)
Sets the material that a character in the recipe shape refers to.
|
ShapedRecipe |
setIngredient(char key,
MaterialData ingredient)
Sets the material that a character in the recipe shape refers to.
|
ShapedRecipe |
setIngredient(char key,
Material ingredient,
int raw)
已过时。
Magic value
|
ShapedRecipe |
shape(java.lang.String... shape)
Set the shape of this recipe to the specified rows.
|
@Deprecated public ShapedRecipe(ItemStack result)
public ShapedRecipe(NamespacedKey key, ItemStack result)
key
- the unique recipe keyresult
- The item you want the recipe to create.shape(String...)
,
setIngredient(char, Material)
,
setIngredient(char, Material, int)
,
setIngredient(char, MaterialData)
public ShapedRecipe shape(java.lang.String... shape)
shape
- The rows of the recipe (up to 3 rows).public ShapedRecipe setIngredient(char key, MaterialData ingredient)
key
- The character that represents the ingredient in the shape.ingredient
- The ingredient.public ShapedRecipe setIngredient(char key, Material ingredient)
key
- The character that represents the ingredient in the shape.ingredient
- The ingredient.@Deprecated public ShapedRecipe setIngredient(char key, Material ingredient, int raw)
key
- The character that represents the ingredient in the shape.ingredient
- The ingredient.raw
- The raw material data as an integer.public java.util.Map<java.lang.Character,ItemStack> getIngredientMap()
public java.lang.String[] getShape()
public ItemStack getResult()
public NamespacedKey getKey()
Keyed