diff --git a/docs/groovy-script/mods/botania-ceu/index.md b/docs/groovy-script/mods/botania-ceu/index.md new file mode 100644 index 0000000..8317293 --- /dev/null +++ b/docs/groovy-script/mods/botania-ceu/index.md @@ -0,0 +1,27 @@ +--- +aside: false +--- + +# Botania CEu + +These features require at least Botania CEu 1.10-r370. + +In addition to the new categories, Botania CEu also changes the following in the official Groovyscript integration: + +* Runic Altar and Petal Apothecary's recipe builders will use the machines' capacity as configured in the mod (default 16) rather than an arbitrary value of 20. + +* Botanical Brewery recipe builder will use the machine's capacity as configured in the mod (default 6). + +Otherwise, integration with all vanilla Botania features works out of the box. + +## Categories + +Has 4 subcategories. + +* [Petal Apothecary Catalysts](./petal_apothecary_catalysts.md) + +* [Runic Altar Catalysts](./runic_altar_catalysts.md) + +* [Runic Altar Retained Items](./runic_altar_retained_items.md) + +* [Terrestrial Agglomeration Plate](./terrestrial_agglomeration_plate.md) diff --git a/docs/groovy-script/mods/botania-ceu/petal_apothecary_catalysts.md b/docs/groovy-script/mods/botania-ceu/petal_apothecary_catalysts.md new file mode 100644 index 0000000..8643881 --- /dev/null +++ b/docs/groovy-script/mods/botania-ceu/petal_apothecary_catalysts.md @@ -0,0 +1,65 @@ +--- +title: "Petal Apothecary Catalysts" +titleTemplate: "Botania CEu | CleanroomMC" +description: "Allows configuring items used to finalize recipes in Petal Apothecary instead of seeds. Has the same effect as adding them through the config file." +source_code_link: "https://github.com/TeamDimensional/Botania-CEu/blob/1.12/src/main/java/vazkii/botania/client/integration/groovyscript/PetalApothecaryCatalysts.java" +--- + +# Petal Apothecary Catalysts (Botania) + +## Description + +Allows configuring items used to finalize recipes in Petal Apothecary instead of seeds. Has the same effect as adding them through the config file. + +:::::::::: details Warning {open id="warning"} +The default list of catalysts is empty, which has a special behavior of "any seeds can be used as a catalyst". This special behavior is removed when any items are added as catalysts. +:::::::::: + +## Identifier + +The identifier `mods.botania.petal_apothecary_catalysts` will be used as the default on this page. + +:::::::::: details All Identifiers {id="quote"} + +Any of these can be used to refer to this compat: + +```groovy:no-line-numbers {8} +mods.Botania.petalapothecarycatalysts +mods.Botania.petalApothecaryCatalysts +mods.Botania.PetalApothecaryCatalysts +mods.botania.petalapothecarycatalysts +mods.botania.petalApothecaryCatalysts +mods.botania.PetalApothecaryCatalysts +mods.Botania.petal_apothecary_catalysts +mods.botania.petal_apothecary_catalysts/* Used as page default */ // [!code focus] +mods.botania_ceu.petalapothecarycatalysts +mods.botania_ceu.petalApothecaryCatalysts +mods.botania_ceu.PetalApothecaryCatalysts +mods.botania_ceu.petal_apothecary_catalysts +``` + +:::::::::: + +## Adding Recipes + +- Adds a new catalyst: + + ```groovy:no-line-numbers + mods.botania.petal_apothecary_catalysts.add(ItemStack) + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.petal_apothecary_catalysts.add(item('minecraft:sapling')) +``` + +:::::::::: + +## Removing Recipes + +- Removes a catalyst: + + ```groovy:no-line-numbers + mods.botania.petal_apothecary_catalysts.remove(ItemStack) + ``` diff --git a/docs/groovy-script/mods/botania-ceu/runic_altar_catalysts.md b/docs/groovy-script/mods/botania-ceu/runic_altar_catalysts.md new file mode 100644 index 0000000..aaad5b3 --- /dev/null +++ b/docs/groovy-script/mods/botania-ceu/runic_altar_catalysts.md @@ -0,0 +1,69 @@ +--- +title: "Runic Altar Catalysts" +titleTemplate: "Botania CEu | CleanroomMC" +description: "Allows configuring items used to activate Runic Altar recipes instead of Livingrock. Has the same effect as adding them through the config file." +source_code_link: "https://github.com/TeamDimensional/Botania-CEu/blob/1.12/src/main/java/vazkii/botania/client/integration/groovyscript/RunicAltarCatalysts.java" +--- + +# Runic Altar Catalysts (Botania) + +## Description + +Allows configuring items used to activate Runic Altar recipes instead of Livingrock. Has the same effect as adding them through the config file. + +## Identifier + +The identifier `mods.botania.runic_altar_catalysts` will be used as the default on this page. + +:::::::::: details All Identifiers {id="quote"} + +Any of these can be used to refer to this compat: + +```groovy:no-line-numbers {8} +mods.Botania.runicaltarcatalysts +mods.Botania.runicAltarCatalysts +mods.Botania.RunicAltarCatalysts +mods.botania.runicaltarcatalysts +mods.botania.runicAltarCatalysts +mods.botania.RunicAltarCatalysts +mods.Botania.runic_altar_catalysts +mods.botania.runic_altar_catalysts/* Used as page default */ // [!code focus] +mods.botania_ceu.runicaltarcatalysts +mods.botania_ceu.runicAltarCatalysts +mods.botania_ceu.RunicAltarCatalysts +mods.botania_ceu.runic_altar_catalysts +``` + +:::::::::: + +## Adding Recipes + +- Adds a new catalyst, making it impossible to use it in Runic Altar recipes: + + ```groovy:no-line-numbers + mods.botania.runic_altar_catalysts.add(ItemStack) + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.runic_altar_catalysts.add(item('minecraft:gold_block')) +``` + +:::::::::: + +## Removing Recipes + +- Removes a catalyst and makes it possible to use this item in Runic Altar recipes: + + ```groovy:no-line-numbers + mods.botania.runic_altar_catalysts.remove(ItemStack) + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.runic_altar_catalysts.remove(item('botania:livingrock')) +``` + +:::::::::: diff --git a/docs/groovy-script/mods/botania-ceu/runic_altar_retained_items.md b/docs/groovy-script/mods/botania-ceu/runic_altar_retained_items.md new file mode 100644 index 0000000..91e9e19 --- /dev/null +++ b/docs/groovy-script/mods/botania-ceu/runic_altar_retained_items.md @@ -0,0 +1,69 @@ +--- +title: "Runic Altar Retained Items" +titleTemplate: "Botania CEu | CleanroomMC" +description: "Allows configuring items that will be dropped out of the Runic Altar at the end of the recipe rather than being consumed. Has the same effect as adding them through the config file." +source_code_link: "https://github.com/TeamDimensional/Botania-CEu/blob/1.12/src/main/java/vazkii/botania/client/integration/groovyscript/RunicAltarRetainedItems.java" +--- + +# Runic Altar Retained Items (Botania) + +## Description + +Allows configuring items that will be dropped out of the Runic Altar at the end of the recipe rather than being consumed. Has the same effect as adding them through the config file. + +## Identifier + +The identifier `mods.botania.runic_altar_retained_items` will be used as the default on this page. + +:::::::::: details All Identifiers {id="quote"} + +Any of these can be used to refer to this compat: + +```groovy:no-line-numbers {8} +mods.Botania.runicaltarretaineditems +mods.Botania.runicAltarRetainedItems +mods.Botania.RunicAltarRetainedItems +mods.botania.runicaltarretaineditems +mods.botania.runicAltarRetainedItems +mods.botania.RunicAltarRetainedItems +mods.Botania.runic_altar_retained_items +mods.botania.runic_altar_retained_items/* Used as page default */ // [!code focus] +mods.botania_ceu.runicaltarretaineditems +mods.botania_ceu.runicAltarRetainedItems +mods.botania_ceu.RunicAltarRetainedItems +mods.botania_ceu.runic_altar_retained_items +``` + +:::::::::: + +## Adding Recipes + +- Adds a retained item: + + ```groovy:no-line-numbers + mods.botania.runic_altar_retained_items.add(ItemStack) + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.runic_altar_retained_items.add(item('botania:manaresource')) +``` + +:::::::::: + +## Removing Recipes + +- Removes a retained item: + + ```groovy:no-line-numbers + mods.botania.runic_altar_retained_items.remove(ItemStack) + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.runic_altar_retained_items.remove(item('botania:rune', 1)) +``` + +:::::::::: diff --git a/docs/groovy-script/mods/botania-ceu/terrestrial_agglomeration_plate.md b/docs/groovy-script/mods/botania-ceu/terrestrial_agglomeration_plate.md new file mode 100644 index 0000000..3f9af79 --- /dev/null +++ b/docs/groovy-script/mods/botania-ceu/terrestrial_agglomeration_plate.md @@ -0,0 +1,179 @@ +--- +title: "Terrestrial Agglomeration Plate" +titleTemplate: "Botania CEu | CleanroomMC" +description: "Transforms any number of items put on top of a Terrestrial Agglomeration Plate into another item with a mana cost. Requires a specific layout of the 3x3 blocks underneath the plate, and can optionally transform them." +source_code_link: "https://github.com/TeamDimensional/Botania-CEu/blob/1.12/src/main/java/vazkii/botania/client/integration/groovyscript/TerrestrialAgglomerationPlate.java" +--- + +# Terrestrial Agglomeration Plate (Botania) + +## Description + +Transforms any number of items put on top of a Terrestrial Agglomeration Plate into another item with a mana cost. Requires a specific layout of the 3x3 blocks underneath the plate, and can optionally transform them. + +## Identifier + +The identifier `mods.botania.terrestrial_agglomeration_plate` will be used as the default on this page. + +:::::::::: details All Identifiers {id="quote"} + +Any of these can be used to refer to this compat: + +```groovy:no-line-numbers {8} +mods.Botania.terrestrialagglomerationplate +mods.Botania.terrestrialAgglomerationPlate +mods.Botania.TerrestrialAgglomerationPlate +mods.botania.terrestrialagglomerationplate +mods.botania.terrestrialAgglomerationPlate +mods.botania.TerrestrialAgglomerationPlate +mods.Botania.terrestrial_agglomeration_plate +mods.botania.terrestrial_agglomeration_plate/* Used as page default */ // [!code focus] +mods.botania_ceu.terrestrialagglomerationplate +mods.botania_ceu.terrestrialAgglomerationPlate +mods.botania_ceu.TerrestrialAgglomerationPlate +mods.botania_ceu.terrestrial_agglomeration_plate +``` + +:::::::::: + +## Adding Recipes + +- Add the given recipe to the recipe list: + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.add(RecipeTerrestrialAgglomeration) + ``` + +### Recipe Builder + +Just like other recipe types, the Terrestrial Agglomeration Plate also uses a recipe builder. + +Don't know what a builder is? Check [the builder info page](../../getting_started/builder.md) out. + +:::::::::: details Recipe Builder {open id="abstract"} + +--- + +- Create the Recipe Builder. + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.recipeBuilder() + ``` + +--- + +- `IngredientList`. Sets the item inputs of the recipe. Requires greater than or equal to 1. + + ```groovy:no-line-numbers + input(IIngredient) + input(IIngredient...) + input(Collection) + ``` + +- `ItemStackList`. Sets the item outputs of the recipe. Requires exactly 1. + + ```groovy:no-line-numbers + output(ItemStack) + output(ItemStack...) + output(Collection) + ``` + +- `int`. Mana cost of the recipe. 1 mana pool is 1 million. Requires greater than or equal to 1. (Default `0`). + + ```groovy:no-line-numbers + mana(int) + ``` + +- `IBlockState[]`. Blocks required underneath the plate, or blocks that will be created under the plate when the recipe is done. The replacement blocks may be `null`, which makes the recipe keep that block intact. Uses the layout for the vanilla Terrasteel recipe (Livingrock in the center and on the corners, Lapis blocks on the edges) by default. + + ```groovy:no-line-numbers + edgeBlock(IBlockState) + centerBlock(IBlockState) + cornerBlock(IBlockState) + edgeBlockReplacement(IBlockState) + centerBlockReplacement(IBlockState) + cornerBlockReplacement(IBlockState) + ``` + +- `int`. Starting color of the particles displayed when executing the recipe. (Default `0x0000FF`). + + ```groovy:no-line-numbers + colorStart(int) + ``` + +- `int`. Ending color of the particles displayed when executing the recipe. (Default `0x00FF00`). + + ```groovy:no-line-numbers + colorEnd(int) + ``` + +--- + +- First validates the builder, returning `null` and outputting errors to the log file if the validation failed, then registers the builder and returns the registered object. (returns `null` or `vazkii.botania.api.recipe.RecipeTerrestrialAgglomeration`). + + ```groovy:no-line-numbers + register() + ``` + +--- + +::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.terrestrial_agglomeration_plate.recipeBuilder() + .input(item('minecraft:iron_ingot'), ore('ingotManasteel'), item('minecraft:stone') * 2) + .output(item('minecraft:diamond')) + .mana(150000) + .colorStart(0xFF0000) + .colorEnd(0xFFFF00) + .register() + +mods.botania.terrestrial_agglomeration_plate.recipeBuilder() + .input(item('minecraft:diamond')) + .output(item('minecraft:dirt')) + .mana(1000000) + .centerBlock(blockstate('minecraft:dirt')) + .centerBlockReplacement(blockstate('minecraft:diamond_block')) + .register() +``` + +::::::::: + +:::::::::: + +## Removing Recipes + +- Removes the given recipe from the recipe list: + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.remove(RecipeTerrestrialAgglomeration) + ``` + +- Removes all recipes that match the given output: + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.removeByOutput(IIngredient) + ``` + +- Removes all registered recipes: + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.removeAll() + ``` + +:::::::::: details Example {open id="example"} + +```groovy:no-line-numbers +mods.botania.terrestrial_agglomeration_plate.removeByOutput(item('botania:manaresource', 4)) +mods.botania.terrestrial_agglomeration_plate.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: + + ```groovy:no-line-numbers + mods.botania.terrestrial_agglomeration_plate.streamRecipes() + ```