![]() |
Bukkit
1.4.7-R1.0
|
Represents a shaped (ie normal) crafting recipe. More...
Inheritance diagram for org.bukkit.inventory.ShapedRecipe:
Collaboration diagram for org.bukkit.inventory.ShapedRecipe:Public Member Functions | |
| ShapedRecipe (ItemStack result) | |
| Create a shaped recipe to craft the specified ItemStack. | |
| ShapedRecipe | shape (final String...shape) |
| Set the shape of this recipe to the specified rows. | |
| ShapedRecipe | setIngredient (char key, MaterialData ingredient) |
| Sets the material that a character in the recipe shape refers to. | |
| ShapedRecipe | setIngredient (char key, Material ingredient) |
| Sets the material that a character in the recipe shape refers to. | |
| ShapedRecipe | setIngredient (char key, Material ingredient, int raw) |
| Sets the material that a character in the recipe shape refers to. | |
| Map< Character, ItemStack > | getIngredientMap () |
| Get a copy of the ingredients map. | |
| String[] | getShape () |
| Get the shape. | |
| ItemStack | getResult () |
| Get the result. | |
Public Member Functions inherited from org.bukkit.inventory.Recipe | |
| ItemStack | getResult () |
| Get the result of this recipe. | |
Represents a shaped (ie normal) crafting recipe.
Definition at line 14 of file ShapedRecipe.java.
| org.bukkit.inventory.ShapedRecipe.ShapedRecipe | ( | ItemStack | result | ) |
Create a shaped recipe to craft the specified ItemStack.
The constructor merely determines the result and type; to set the actual recipe, you'll need to call the appropriate methods.
| result | The item you want the recipe to create. |
Definition at line 29 of file ShapedRecipe.java.
| Map<Character, ItemStack> org.bukkit.inventory.ShapedRecipe.getIngredientMap | ( | ) |
Get a copy of the ingredients map.
Definition at line 108 of file ShapedRecipe.java.
| ItemStack org.bukkit.inventory.ShapedRecipe.getResult | ( | ) |
Get the result.
Definition at line 134 of file ShapedRecipe.java.
References org.bukkit.inventory.ItemStack.clone().
| String [] org.bukkit.inventory.ShapedRecipe.getShape | ( | ) |
| ShapedRecipe org.bukkit.inventory.ShapedRecipe.setIngredient | ( | char | key, |
| MaterialData | ingredient | ||
| ) |
Sets the material that a character in the recipe shape refers to.
| key | The character that represents the ingredient in the shape. |
| ingredient | The ingredient. |
Definition at line 74 of file ShapedRecipe.java.
References org.bukkit.material.MaterialData.getData(), and org.bukkit.material.MaterialData.getItemType().
Referenced by org.bukkit.inventory.ShapedRecipe.setIngredient().
| ShapedRecipe org.bukkit.inventory.ShapedRecipe.setIngredient | ( | char | key, |
| Material | ingredient | ||
| ) |
Sets the material that a character in the recipe shape refers to.
| key | The character that represents the ingredient in the shape. |
| ingredient | The ingredient. |
Definition at line 85 of file ShapedRecipe.java.
References org.bukkit.inventory.ShapedRecipe.setIngredient().
| ShapedRecipe org.bukkit.inventory.ShapedRecipe.setIngredient | ( | char | key, |
| Material | ingredient, | ||
| int | raw | ||
| ) |
Sets the material that a character in the recipe shape refers to.
| key | The character that represents the ingredient in the shape. |
| ingredient | The ingredient. |
| raw | The raw material data as an integer. |
Definition at line 97 of file ShapedRecipe.java.
| ShapedRecipe org.bukkit.inventory.ShapedRecipe.shape | ( | final String... | shape | ) |
Set the shape of this recipe to the specified rows.
Each character represents a different ingredient; exactly what each character represents is set separately. The first row supplied corresponds with the upper most part of the recipe on the workbench e.g. if all three rows are supplies the first string represents the top row on the workbench.
| shape | The rows of the recipe (up to 3 rows). |
Definition at line 42 of file ShapedRecipe.java.