File tree Expand file tree Collapse file tree
src/main/java/minevalley/crafting/api/recipe Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package minevalley .crafting .api .recipe ;
22
33import minevalley .core .api .users .OnlineUser ;
4- import minevalley .crafting .api .ingredient .RecipeIngredient ;
54import org .bukkit .inventory .ItemStack ;
65import org .jetbrains .annotations .Contract ;
76
@@ -28,16 +27,6 @@ public interface CustomRecipe {
2827 @ Contract (pure = true )
2928 long getCraftingDurationMs ();
3029
31- /**
32- * Maps a symbol in the recipe shape to a crafting ingredient.
33- *
34- * @param symbol the symbol to map
35- * @param ingredient the crafting ingredient to map to the symbol
36- * @return this
37- * @throws IllegalArgumentException if the symbol is already mapped or if the ingredient is null
38- */
39- CustomRecipe mapIngredient (char symbol , @ Nonnull RecipeIngredient ingredient ) throws IllegalArgumentException ;
40-
4130 /**
4231 * Sets a requirement that must be fulfilled by the user trying to craft this recipe.
4332 *
Original file line number Diff line number Diff line change 88@ SuppressWarnings ("unused" )
99public interface CustomShapedRecipe extends CustomRecipe {
1010
11+ /**
12+ * Maps a symbol in the recipe shape to a crafting ingredient.
13+ *
14+ * @param symbol the symbol to map
15+ * @param ingredient the crafting ingredient to map to the symbol
16+ * @return this
17+ * @throws IllegalArgumentException if the symbol is already mapped or if the ingredient is null
18+ */
19+ CustomShapedRecipe mapIngredient (char symbol , @ Nonnull RecipeIngredient ingredient ) throws IllegalArgumentException ;
20+
1121 /**
1222 * Gets the ingredients arranged in the shape of the recipe.
1323 *
Original file line number Diff line number Diff line change 11package minevalley .crafting .api .recipe ;
22
3+ import minevalley .crafting .api .ingredient .RecipeIngredient ;
4+
5+ import javax .annotation .Nonnull ;
6+
37@ SuppressWarnings ("unused" )
48public interface CustomShapelessRecipe extends CustomRecipe {
59
10+ /**
11+ * Adds an ingredient to the recipe.
12+ *
13+ * @param ingredient the ingredient to add
14+ * @return this
15+ * @throws IllegalArgumentException if the ingredient is null
16+ */
17+ CustomShapelessRecipe addIngredient (@ Nonnull RecipeIngredient ingredient ) throws IllegalArgumentException ;
618}
You can’t perform that action at this time.
0 commit comments