High-Tech Bench (Armor Plus)
Description
A normal crafting recipe, but with a 5x5 grid and in the High-Tech Bench.
Identifier
Refer to this via any of the following:
mods.armorplus.high_tech_bench/* Used as page default */
mods.armorplus.hightechbench
mods.armorplus.highTechBench
mods.armorplus.HighTechBenchAdding Recipes
Add the given recipe to the recipe list:
groovymods.armorplus.high_tech_bench.add(R)
Recipe Builder
Just like other recipe types, the High-Tech Bench also uses a recipe builder.
Don't know what a builder is? Check the builder info page out.
Recipe Builder
Create the Recipe Builder.
groovymods.armorplus.high_tech_bench.shapedBuilder()
ResourceLocation. Sets the Resource Location of the recipe.groovyname(String) name(ResourceLocation)String[]. Sets the items required in each slot of the grid as char. Requires either the key-based matrix or the ingredient-based matrix can be defined, not both.groovyrow(String) shape(String...) matrix(String...)List<List<IIngredient>>. Sets the items required in each slot in the grid as IIngredients. Requires greater than or equal to 1, less than or equal to 9, and either the key-based matrix or the ingredient-based matrix can be defined, not both.groovyshape(List<List<IIngredient>>) matrix(List<List<IIngredient>>)Char2ObjectOpenHashMap<IIngredient>. Sets the item the given char corresponds to. (Default' ' = IIngredient.EMPTY).groovykey(char, IIngredient) key(String, IIngredient) key(Map<String, IIngredient>)ItemStack. Sets the item output. Requires not null.groovyoutput(ItemStack)boolean. Sets if the recipe is horizontally mirrored. (Defaultfalse).groovymirrored() mirrored(boolean)Closure<ItemStack>. Sets an operation that modifies the input items or output item.groovyrecipeFunction(Closure<ItemStack>)Closure<Void>. Sets an operation that happens when the recipe is crafted.groovyrecipeAction(Closure<Void>)
First validates the builder, returning
nulland outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returnsnullorcom.sofodev.armorplus.api.crafting.IRecipe).groovyregister()
Recipe Builder
Create the Recipe Builder.
groovymods.armorplus.high_tech_bench.shapedBuilder()
ResourceLocation. Sets the Resource Location of the recipe.groovyname(String) name(ResourceLocation)String[]. Sets the items required in each slot of the grid as char. Requires either the key-based matrix or the ingredient-based matrix can be defined, not both.groovyrow(String) shape(String...) matrix(String...)List<List<IIngredient>>. Sets the items required in each slot in the grid as IIngredients. Requires greater than or equal to 1, less than or equal to 9, and either the key-based matrix or the ingredient-based matrix can be defined, not both.groovyshape(List<List<IIngredient>>) matrix(List<List<IIngredient>>)Char2ObjectOpenHashMap<IIngredient>. Sets the item the given char corresponds to. (Default' ' = IIngredient.EMPTY).groovykey(char, IIngredient) key(String, IIngredient) key(Map<String, IIngredient>)ItemStack. Sets the item output. Requires not null.groovyoutput(ItemStack)boolean. Sets if the recipe is horizontally mirrored. (Defaultfalse).groovymirrored() mirrored(boolean)Closure<ItemStack>. Sets an operation that modifies the input items or output item.groovyrecipeFunction(Closure<ItemStack>)Closure<Void>. Sets an operation that happens when the recipe is crafted.groovyrecipeAction(Closure<Void>)
First validates the builder, returning
nulland outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returnsnullorcom.sofodev.armorplus.api.crafting.IRecipe).groovyregister()
Example
mods.armorplus.high_tech_bench.shapedBuilder()
.output(item('minecraft:diamond') * 32)
.matrix([[item('minecraft:gold_ingot'), item('minecraft:gold_ingot'), item('minecraft:gold_ingot')],
[item('minecraft:gold_ingot'), item('minecraft:gold_ingot'), item('minecraft:gold_ingot')],
[item('minecraft:gold_ingot'), item('minecraft:gold_ingot'), item('minecraft:gold_ingot')]])
.register()Recipe Builder
Create the Recipe Builder.
groovymods.armorplus.high_tech_bench.shapelessBuilder()
ResourceLocation. Sets the Resource Location of the recipe.groovyname(String) name(ResourceLocation)List<IIngredient>. Sets the items required for the recipe. Requires greater than or equal to 1 and less than or equal to 9.groovyinput(IIngredient) input(IIngredient...) input(Collection<IIngredient>)ItemStack. Sets the item output. Requires not null.groovyoutput(ItemStack)Closure<ItemStack>. Sets an operation that modifies the input items or output item.groovyrecipeFunction(Closure<ItemStack>)Closure<Void>. Sets an operation that happens when the recipe is crafted.groovyrecipeAction(Closure<Void>)
First validates the builder, returning
nulland outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returnsnullorcom.sofodev.armorplus.api.crafting.IRecipe).groovyregister()
Recipe Builder
Create the Recipe Builder.
groovymods.armorplus.high_tech_bench.shapelessBuilder()
ResourceLocation. Sets the Resource Location of the recipe.groovyname(String) name(ResourceLocation)List<IIngredient>. Sets the items required for the recipe. Requires greater than or equal to 1, less than or equal to 9, and either the key-based matrix or the ingredient-based matrix can be defined, not both.groovyinput(IIngredient) input(IIngredient...) input(Collection<IIngredient>)ItemStack. Sets the item output. Requires not null.groovyoutput(ItemStack)Closure<ItemStack>. Sets an operation that modifies the input items or output item.groovyrecipeFunction(Closure<ItemStack>)Closure<Void>. Sets an operation that happens when the recipe is crafted.groovyrecipeAction(Closure<Void>)
First validates the builder, returning
nulland outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returnsnullorcom.sofodev.armorplus.api.crafting.IRecipe).groovyregister()
Example
mods.armorplus.high_tech_bench.shapelessBuilder()
.output(item('minecraft:clay') * 8)
.input(item('minecraft:stone'), item('minecraft:stone'), item('minecraft:stone'))
.register()Removing Recipes
Removes the given recipe from the recipe list:
groovymods.armorplus.high_tech_bench.remove(R)Removes all recipes that match the given output:
groovymods.armorplus.high_tech_bench.removeByOutput(IIngredient)Removes all registered recipes:
groovymods.armorplus.high_tech_bench.removeAll()
Example
mods.armorplus.high_tech_bench.removeByOutput(item('armorplus:emerald_helmet'))
mods.armorplus.high_tech_bench.removeAll()Getting the value of recipes
Iterates through every entry in the registry, with the ability to call remove on any element to remove it:
groovymods.armorplus.high_tech_bench.streamRecipes()
