Represent minecraft recipes
const Recipe=require("prismarine-recipe")("1.8").Recipe;
console.log(JSON.stringify(Recipe.find(5)[0],null,2)); // recipes for wood
Returns a list of matching Recipe
instances.
-
itemType
- numerical id -
metadata
- metadata to match.null
means match anything.
The output item. It's a recipeItem :
{
id:45,
metadata:3,
count:1
}
Looks like this:
[
[recipeItem, recipeItem],
[recipeItem, recipeItem],
[recipeItem, recipeItem],
]
Looks the same as inShape
. Only relevant for cake.
List of shape-independent ingredients. Looks like this:
[
recipeItem,
recipeItem
]
Boolean.
Map of item type to how much more or less you will have after you use the recipe.
This is what it looks like for the chest recipe:
[
recipeItem,
recipeItem
]
- mcData to registry refactoring (@Epirito)
- Fixed RecipeItemConstructor Type and default export (@psu-de)
- Bump mcdata
- typescript definitions (thanks @IdanHo)
- bump mcdata
- bump dependencies
- Import from mineflayer