onEvent('recipes', e => {
  e.custom({
    "type": "masterfulmachinery:machine_structure",
    "id": "rsa",
    "controllerId": "rthermalmachine",
    "name": "Resonant Sequential Assembler",
    "layout": [
      [
        " ))) ",
        "*)))*",
        "+))),",
        "+))),",
        "+))),",
        "*)))*",
        " )C) "
      ],
      [
        " )-) ",
        "*)))*",
        "+))),",
        "+))),",
        "+))),",
        "*)))*",
        " ))) "
      ],
      [
        " .*. ",
        ".***.",
        "**/**",
        "*)))*",
        "**/**",
        ".***.",
        " .*. "
      ],
      [
        "     ",
        "     ",
        " . . ",
        " ... ",
        " . . ",
        "     ",
        "     "
      ]
    ],
    "legend": {
      ")": {
        "block": "kubejs:rtme"
      },
      "*": {
        "block": "immersiveengineering:sheetmetal_steel"
      },
      "+": {
        "block": "masterfulmachinery:rthermalmachine_rthermalitem_port_items_input"
      },
      ",": {
        "block": "masterfulmachinery:rthermalmachine_rthermaltank_port_fluids_input"
      },
      "-": {
        "block": "masterfulmachinery:rthermalmachine_rthermalitem_port_items_output"
      },
      ".": {
        "block": "immersiveengineering:slab_sheetmetal_steel"
      },
      "/": {
        "block": "masterfulmachinery:rthermalmachine_rthermalbank_port_energy_input"
      }
    }
  })
})

onEvent('recipes', e => {

  e.custom({
    "type": "masterfulmachinery:machine_process",
    "structureId": "rsa",
    "controllerId": "rthermalmachine",
    "ticks": 350,
    "inputs": [
      {
        "type": "masterfulmachinery:energy",
        "perTick": true,
        "data": {
          "amount": 10000
        }
      },
      {
        "type": "masterfulmachinery:fluids",
        "data": {
          "fluid": 'thermal:redstone',
          "amount": 450
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'mekanism:steel_casing',
          "count": 2
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'immersiveengineering:storage_aluminum',
          "count": 2
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:rf_coil',
          "count": 4
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:invar_ingot',
          "count": 16
        }
      }

    ],
    "outputs": [
      {
        "type": "masterfulmachinery:items",
        "data": {
          "item": 'mekanism:boiler_casing',
          "count": 8,
        }
      }
    ]
  })

  e.custom({
    "type": "masterfulmachinery:machine_process",
    "structureId": "rsa",
    "controllerId": "rthermalmachine",
    "ticks": 350,
    "inputs": [
      {
        "type": "masterfulmachinery:energy",
        "perTick": true,
        "data": {
          "amount": 10000
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:redstone',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:glowstone_dust',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'appliedenergistics2:fluix_glass_cable',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:white_wool',
          "count": 16
        }
      }

    ],
    "outputs": [
      {
        "type": "masterfulmachinery:items",
        "data": {
          "item": 'appliedenergistics2:fluix_smart_cable',
          "count": 32,
        }
      }
    ]
  })

  e.custom({
    "type": "masterfulmachinery:machine_process",
    "structureId": "rsa",
    "controllerId": "rthermalmachine",
    "ticks": 350,
    "inputs": [
      {
        "type": "masterfulmachinery:energy",
        "perTick": true,
        "data": {
          "amount": 100000
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:redstone',
          "count": 64
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:glowstone_dust',
          "count": 64
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'appliedenergistics2:fluix_smart_cable',
          "count": 64
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'minecraft:white_wool',
          "count": 48
        }
      }

    ],
    "outputs": [
      {
        "type": "masterfulmachinery:items",
        "data": {
          "item": 'appliedenergistics2:fluix_smart_dense_cable',
          "count": 32,
        }
      }
    ]
  })

  
  e.custom({
    "type": "masterfulmachinery:machine_process",
    "structureId": "rsa",
    "controllerId": "rthermalmachine",
    "ticks": 400,
    "inputs": [
      {
        "type": "masterfulmachinery:energy",
        "perTick": true,
        "data": {
          "amount": 10000
        }
      },
      {
        "type": "masterfulmachinery:fluids",
        "data": {
          "fluid": 'thermal:resin',
          "amount": 450
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'kubejs:machineframe',
          "count": 2
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:redstone_servo',
          "count": 2
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:rf_coil',
          "count": 4
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:lumium_ingot',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:enderium_ingot',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:signalum_ingot',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'thermal:upgrade_augment_3',
          "count": 1
        }
      }

    ],
    "outputs": [
      {
        "type": "masterfulmachinery:items",
        "data": {
          "item": 'kubejs:resonantmachineframe',
          "count": 1,
        }
      }
    ]
  })

  e.custom({
    "type": "masterfulmachinery:machine_process",
    "structureId": "rsa",
    "controllerId": "rthermalmachine",
    "ticks": 350,
    "inputs": [
      {
        "type": "masterfulmachinery:energy",
        "perTick": true,
        "data": {
          "amount": 10000
        }
      },
      {
        "type": "masterfulmachinery:fluids",
        "data": {
          "fluid": 'tconstruct:molten_lumium',
          "amount": 1000
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'extendedcrafting:luminessence_block',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'kubejs:eliteframe',
          "count": 16
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'appliedenergistics2:fluix_glass_cable',
          "count": 32
        }
      },
      {
        "type": "masterfulmachinery:items",
        "consumeInstantly": true,
        "data": {
          "item": 'appliedenergistics2:4k_cell_component',
          "count": 16
        }
      }

    ],
    "outputs": [
      {
        "type": "masterfulmachinery:items",
        "data": {
          "item": 'kubejs:mb',
          "count": 4,
        }
      }
    ]
  })


})