Digital Crafter
Appearance
Description
Provided component
This block provides the digitalCrafter component, offering the following properties:
| Name | Type | Read/Write | Description |
|---|---|---|---|
cooldownRemaining
|
number
|
READ | How much more time needs to pass before :craft may be called again.
|
| Name | Type | Description |
|---|---|---|
:searchRecipesWithIngredient(ingredient:string)
|
recipe[]
|
Returns all crafting recipes that use ingredient as an input. The ingredient needs to be in the format modname:itemname, e.g. minecraft:stick.
The result is a table of recipes, where each recipe is again a table that looks like the following:
|
:searchRecipesWithResult(string"modname:itemname")
|
recipe[]
|
|
:searchItemByName(string:partialName)
|
string
|
Returns the full name of the item |
:craft(string"modname:itemname"[]:ingredients, string"modname:itemname":resultItem, int:amount, boolean:outputIntoOwnInventory)
|
integer
|
If all required items are available, crafts the result. If outputIntoOwnInventory is true the result is put into the own inventory. Otherwise it is pushed into the inventory that may be above, or it is ejected above in-world. Beware that there is no destination check to make sure that there is room in the inventory above, so items may spill if the destination is full.
|