Ritual
Link to ritual
Importing the class
Link to importing-the-class
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
ZenScript Copyimport mods.rootsclassic.Ritual;
Static Methods
Link to static-methods
Name: addCraftingRitual
ZenScript Copy// Ritual.addCraftingRitual(uniqueName as string, output as IItemStack, level as int, r as double, g as double, b as double, incenses as IItemStack[], ingredients as IItemStack[])
Ritual.addCraftingRitual("devil_summoning", <item:minecraft:blaze_spawn_egg>, 1, 255, 59, 100, [<item:minecraft:fire_coral>, <item:minecraft:fire_coral>, <item:minecraft:fire_coral>, <item:minecraft:fire_coral>], [<item:minecraft:netherrack>, <item:minecraft:netherrack>, <item:minecraft:blaze_powder>]);
Parameter | Type | Description |
---|---|---|
Parameter uniqueName | Type string | Description The unique name of the recipe |
Parameter output | Type IItemStack | Description The IItemStack to output |
Parameter level | Type int | Description The level of the recipe |
Parameter r | Type double | Description The red amount of colour (0-255 value) |
Parameter g | Type double | Description The green amount of colour (0-255 value) |
Parameter b | Type double | Description The blue amount of colour (0-255 value) |
Parameter incenses | Type IItemStack[] | Description The incenses that can be used in this recipe |
Parameter ingredients | Type IItemStack[] | Description The ingredients to use in this recipe |
Name: setLevel
Change the level of a recipe, thus affecting the standing stone requirements.
0 requires none, only Braziers
1 requires a 3x3 grid of Mundane Standing Stones
2 requires the 3x3 grid of Mundane Standing Stones plus a rhombus of Attuned Standing Stones.
ZenScript Copy// Ritual.setLevel(name as ResourceLocation, level as int)
Ritual.setLevel(<resource:rootsclassic:igniter_stone_crafting>, 0);
Parameter | Type | Description |
---|---|---|
Parameter name | Type ResourceLocation | Description The name of the existing recipe to manipulate. |
Parameter level | Type int | Description The new requirement level. Values within 0-2 inclusive. |
Name: setPrimaryColor
Modifies the primary Colour of an existing recipe
ZenScript Copy// Ritual.setPrimaryColor(name as ResourceLocation, r as double, g as double, b as double)
Ritual.setPrimaryColor(<resource:crafttweaker:devil_summoning>, 230, 30, 70);
Parameter | Type | Description |
---|---|---|
Parameter name | Type ResourceLocation | Description The name of the existing recipe |
Parameter r | Type double | Description The new red colour of the recipe (0-255) |
Parameter g | Type double | Description The new green colour of the recipe (0-255) |
Parameter b | Type double | Description The new blue colour of the recipe (0-255) |
Name: setRitualIncense
Modifies the required incenses for the provided recipe.
ZenScript Copy// Ritual.setRitualIncense(name as ResourceLocation, items as IItemStack[])
Ritual.setRitualIncense(<resource:rootsclassic:living_sword_crafting>, [<item:minecraft:grass>,<item:minecraft:sand>]);
Parameter | Type | Description |
---|---|---|
Parameter name | Type ResourceLocation | Description The name of the existing recipe to manipulate |
Parameter items | Type IItemStack[] | Description The new incenses to use. |
Name: setRitualIngredients
Manipulates and changes the provided recipe with the new inputs.
Names must be the name of a valid recipe. Roots adds the following:
- staff_crafting,
- sylvan_hood_crafting,
- sylvan_chest_crafting,
- sylvan_legs_crafting,
- sylvan_boots_crafting,
- wildwood_head_crafting,
- wildwood_chest_crafting,
- wildwood_legs_crafting,
- wildwood_boots_crafting,
- accelerator_stone_crafting,
- standing_stone,
- entangler_stone_crafting,
- grower_stone_crafting,
- healer_stone_crafting,
- igniter_stone_crafting,
- repulsor_stone_crafting,
- vacuum_stone_crafting,
- runic_focus_crafting,
- runic_focus_charging,
- living_pickaxe_crafting,
- living_axe_crafting,
- living_sword_crafting,
- living_hoe_crafting,
- living_shovel_crafting,
- cause_rain,
- banish_rain,
- mass_breeding,
- life_drain,
- imbuer,
- cow_summoning,
- pig_summoning,
- sheep_summoning,
- chicken_summoning,
- rabbit_summoning,
- zombie_summoning,
- skeleton_summoning,
- spider_summoning,
- cavespider_summoning,
- slime_summoning,
- creeper_summoning,
- enderman_summoning,
- sacrifice,
- flare,
- grow,
- engraved_crafting,
- time_shift
<resource:rootsclassic
(Example: <resource:rootsclassic:staff_crafting>
)ZenScript Copy// Ritual.setRitualIngredients(name as ResourceLocation, items as IItemStack[])
Ritual.setRitualIngredients(<resource:rootsclassic:accelerator_stone_crafting>, [<item:minecraft:diamond>, <item:minecraft:diamond_block>, <item:minecraft:redstone>]);
Parameter | Type | Description |
---|---|---|
Parameter name | Type ResourceLocation | Description The unique resourcelocation of the recipe to target |
Parameter items | Type IItemStack[] | Description The new inputs to make the recipe use. |
Name: setSecondaryColor
Modifies the secondary Colour of a recipe
ZenScript Copy// Ritual.setSecondaryColor(name as ResourceLocation, r as double, g as double, b as double)
Ritual.setSecondaryColor(<resource:rootsclassic:igniter_stone_crafting>, 255, 0, 0);
Parameter | Type | Description |
---|---|---|
Parameter name | Type ResourceLocation | Description The name of the recipe to manipulate |
Parameter r | Type double | Description The new red colour value (0-255) |
Parameter g | Type double | Description The new green colour value (0-255) |
Parameter b | Type double | Description The new blue colour value (0-255) |