Skip to content

Moonlight Forge (The Aurorian)

Description

Combines two items to get a third item. Only works at night, and works faster the higher it is placed in the world.

Identifier

Refer to this via any of the following:

groovy
mods.aurorian.moonlight_forge
mods.aurorian.moonlightforge
mods.aurorian.moonlightForge
mods.aurorian.MoonlightForge
mods.theaurorian.moonlight_forge/* Used as page default */
mods.theaurorian.moonlightforge
mods.theaurorian.moonlightForge
mods.theaurorian.MoonlightForge

Adding Recipes

  • Add the given recipe to the recipe list:

    groovy
    mods.theaurorian.moonlight_forge.add(MoonlightForgeRecipe)

Recipe Builder

Just like other recipe types, the Moonlight Forge also uses a recipe builder.

Don't know what a builder is? Check the builder info page out.

mods.theaurorian.moonlight_forge.recipeBuilder()
  • IngredientList<IIngredient>. Sets the item inputs of the recipe. Requires exactly 2.

    groovy
    input(IIngredient)
    input(IIngredient...)
    input(Collection<IIngredient>)
  • ItemStackList. Sets the item outputs of the recipe. Requires exactly 1.

    groovy
    output(ItemStack)
    output(ItemStack...)
    output(Collection<ItemStack>)
  • 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 com.shiroroku.theaurorian.Recipes.MoonlightForgeRecipe).

    groovy
    register()
Example
groovy
mods.theaurorian.moonlight_forge.recipeBuilder()
    .input(item('minecraft:stone_sword'), item('minecraft:diamond'))
    .output(item('minecraft:diamond_sword'))
    .register()

Removing Recipes

  • Removes the given recipe from the recipe list:

    groovy
    mods.theaurorian.moonlight_forge.remove(MoonlightForgeRecipe)
  • Removes a recipe by the input item and the catalyst item:

    groovy
    mods.theaurorian.moonlight_forge.removeByInput(IIngredient, IIngredient)
  • Removes all recipes that match the given output:

    groovy
    mods.theaurorian.moonlight_forge.removeByOutput(IIngredient)
  • Removes all registered recipes:

    groovy
    mods.theaurorian.moonlight_forge.removeAll()
Example
groovy
mods.theaurorian.moonlight_forge.removeByInput(item('theaurorian:moonstonesword'), item('theaurorian:aurorianiteingot'))
mods.theaurorian.moonlight_forge.removeByOutput(item('theaurorian:queenschipper'))
mods.theaurorian.moonlight_forge.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
    mods.theaurorian.moonlight_forge.streamRecipes()

Contributors

Changelog

© 2024 CleanroomMC. All Rights Reserved.