ServerEvents.recipes(event => {
    event.remove({output: 'eidolon:codex'})
    event.remove({output: 'eidolon:pewter_inlay'})
    event.remove({output: 'eidolon:worktable'})
    event.remove({output: 'eidolon:necrotic_focus'})
    event.remove({output: 'eidolon:gold_inlay'})
    event.remove({output: 'eidolon:arcane_gold_ingot'})
})

ServerEvents.recipes(event => {
    //Ars Ecclesia
    event.shaped('eidolon:codex',
    ['424','135','4 4'], {
        1: 'hexerei:moon_dust_brush',
        2: 'hexerei:blood_sigil',
        3: 'minecraft:book',
        4: 'minecraft:gold_nugget',
        5: 'hexerei:blood_bottle'
    }).id('eidolon:codex')

    //Pewter Inlay
    event.shaped('eidolon:pewter_inlay',
    [' 1 ','1 1',' 1 '], {
        1: 'eidolon:pewter_ingot'
    }).id('eidolon:pewter_inlay')

    //Arcane Gold Block
    event.shaped('9x eidolon:arcane_gold_ingot',
    ['1'], {
        1: 'eidolon:arcane_gold_block'
    }).id('eidolon:arcane_gold_ingot_to_block')

    //Gold Inlay
    event.shaped('eidolon:gold_inlay',
    [' 1 ','1 1',' 1 '], {
        1: 'eidolon:arcane_gold_ingot'
    }).id('eidolon:gold_inlay')

    //Magic Workbench
    event.shaped('eidolon:worktable',
    [' 1 ','222','333'], {
        1: 'eidolon:pewter_ingot',
        2: 'hexerei:infused_fabric',
        3: '#forge:treated_wood'
    }).id('eidolon:worktable')

    //Necrotic Focus
    event.shaped('eidolon:necrotic_focus',
    ['111','121','343'], {
        1: 'create:andesite_alloy',
        2: 'meetyourfight:caged_heart',
        3: '#forge:ingots/pewter',
        4: 'eidolon:gold_inlay'
    }).id('eidolon:necrotic_focus')

    //Gold Inlay
    event.custom({
        type: 'eidolon:crucible',
        steps: [
            { 
                items: [
                    {
                        item: 'minecraft:redstone'
                    },
                    {
                        item: 'minecraft:redstone'
                    },
                    {
                        item: 'eidolon:soul_shard'
                    }
                ]
            },
            { 
                items: [
                    {
                        tag: 'forge:ingots/brass'
                    },
                    {
                        tag: 'forge:ingots/brass'
                    }
                ]
            }
        ],
        result: {
            item: 'eidolon:arcane_gold_ingot',
            count: 2
        }
    }).id('eidolon:arcane_gold_ingot')
    
    //Essence of Death - Nature's Aura
    event.custom({
    type: 'naturesaura:altar',
        input:{
            item: 'eidolon:zombie_heart',
        },
        output: {
            item: 'eidolon:death_essence',
        },
        aura: 7500,
        time: 40,
    }).id('naturesaura:altar/death_essence')
    
    //Essence of Death - Nature's Aura Alt
    event.custom({
    type: 'naturesaura:altar',
        input:{
            item: 'reliquary:zombie_heart',
        },
        output: {
            item: 'eidolon:death_essence',
        },
        aura: 7500,
        time: 40,
    }).id('naturesaura:altar/death_essence_alt')
    
    //Soul Shard - Nature's Aura
    event.custom({
    type: 'naturesaura:altar',
        input:{
            tag: 'forge:bones',
        },
        output: {
            item: 'eidolon:soul_shard',
        },
        aura: 7500,
        time: 40,
    }).id('naturesaura:altar/soul_shard')
    
    //Shadow Gem Block - Occultism
	event.recipes.occultism.ritual(
		'eidolon:shadow_gem_block',
		[
            "minecraft:ghast_tear",
            "eidolon:soul_shard",
            "eidolon:soul_shard",
            "#forge:storage_blocks/coal",
            "eidolon:death_essence",
            "eidolon:death_essence",
            "eidolon:death_essence",
            "eidolon:death_essence",
            "#forge:storage_blocks/coal",
            "eidolon:soul_shard",
            "eidolon:soul_shard",
            "minecraft:ghast_tear",
		],
		'minecraft:diamond_block',
		'occultism:craft_djinni'
	).duration("20").id('occultism:ritual/shadow_gem_block')
  
    //Arcane Gold Ingot - Induction
    event.custom({
        "type": "thermal:smelter",
        "ingredients": [
          {
            "value": [
              {"tag": "forge:dusts/redstone"}
            ],
            "count": 2
          },
          {
            "value": [
              {"tag": "forge:ingots/brass"}
            ],
            "count": 2
          },
          {
            "value": [
              {"item": "eidolon:soul_shard"}
            ],
            "count": 1
          }
        ],
        "result": [
          {
            "tag": "forge:ingots/arcane_gold",
            "count": 2
          }
        ],
        "energy": 4000
      }).id('eidolon:induction/arcane_gold')
})