Legacy Recipes (for versions pre 2.0.0) - MaxNeedsSnacks/Interactio GitHub Wiki

This page contains examples of the "legacy" recipe syntax, used before mod version 2.0.0

Example of a Fluid to Item Crafting recipe:

{
  "type": "interactio:item_fluid_transform",     // This is the type for any recipes that are (items + fluid) -> item
  "inputs": [                                    // This is an array of input ingredients, using vanilla ingredient syntax.
    {
      "tag":  "minecraft:logs",
      "count": 3
    },
    {
      "item": "minecraft:redstone",
      "count": 2
    }
  ],
  "fluid": {                                    // This is a "fluid ingredient", used in any fluid inputs throughout the mod.
    "fluid": "water"                            // It supports either fluid tags (key: "tag") or single fluids (key: "fluid")
  },                                            // as well as arrays containing either of the two.
  "result": {
    "item": "minecraft:scute",                  // This is the output of the recipe,
    "count": 6                                  // which has to be a single item stack here.
  },
  "consume": 0.75                               // Optional, can be Boolean or Number (chance). default: false / 0.0
}

And another one, this time using nbt tags to convert empty bottles to water bottles (which are actually considered a "potion"):

{
  "type": "interactio:item_fluid_transform",
  "inputs": [
    {
      "item":  "minecraft:glass_bottle",
      "count": 1
    }
  ],
  "fluid": {
    "fluid": "water"
  },
  "result": {
    "item": "minecraft:potion",
    "count": 1,
    "nbt": {
        "Potion": "minecraft:water"
    }
  },
  "consume": 0.33
}

Example of a Fluid Transformation Recipe:

{
  "type": "interactio:fluid_fluid_transform",  // This is the type for any recipes that are (fluid + items) -> fluid
  "items": [
    {
      "tag": "minecraft:logs",                 // I'm honestly not 100% sure how reliable stack sizes > 64 are, but
      "count": 65                              // it worked in all of my test cases, so you should be fine™
    },
    {
      "tag": "forge:chests",
      "count": 1
    }
  ],
  "input": {
    "tag": "water"                             // Another example of a fluid ingredient, this time using a tag.
  },
  "result": "lava",                            // since this only produces a single fluid, we just enter the fluid name here.
  "consume_items": true                        // Optional. Default: false

}

Example of an Item Explosion Recipe:

{
  "type": "interactio:item_explode",
  "inputs": [
    {
      "item": "minecraft:ender_pearl",
      "count": 1
    },
    {
      "tag": "forge:dusts/redstone",
      "count": 2
    }
  ],
  "result": {
    "item": "minecraft:ender_eye",
    "count": 1,
    "nbt": {
      "display": {
        "Name": "{ \"text\": \"a very special ender eye\" }"
      },
      "Enchantments": [
        {
          "id": "minecraft:channeling",
          "lvl": 10
        }
      ],
      "Tags": [
        "special"
      ]
    }
  },
  "chance": 0.2                              // optional, defaults to 100% success.
}

Example of a Block Explosion Recipe:

{
  "type": "interactio:block_explode",
  "input": "minecraft:netherrack",          // has to be either an id or a single item stack,
  "result": "minecraft:obsidian",           // in both cases, it will try to look for a block with the id specified.
  "chance": 0.2                             // chance that the recipe succeeds
  "destroy": true                           // if the recipe fails, should the block be destroyed or just explode normally
}