ServerEvents.recipes((event) => {
    
    let mineCardsList = [
        "minecards:card_set_overworld",
        "minecards:card_the_overworld",
        "minecards:card_grass_block",
        "minecards:card_stone",
        "minecards:card_sand",
        "minecards:card_wood",
        "minecards:card_copper_ore",
        "minecards:card_coal_ore",
        "minecards:card_iron_ore",
        "minecards:card_gold_ore",
        "minecards:card_emerald_ore",
        "minecards:card_lapis_lazuli_ore",
        "minecards:card_diamond_ore",
        "minecards:card_water",
        "minecards:card_lava",
        "minecards:card_air",
        "minecards:card_crafting_table",
        "minecards:card_bed",
        "minecards:card_tnt",
        "minecards:card_zombie",
        "minecards:card_skeleton",
        "minecards:card_spider",
        "minecards:card_player",
        "minecards:card_creeper",
        "minecards:card_diamond_sword",
        "minecards:card_set_nether",
        "minecards:card_the_nether",
        "minecards:card_netherrack",
        "minecards:card_glowstone",
        "minecards:card_nether_quartz",
        "minecards:card_nether_wart",
        "minecards:card_piglin",
        "minecards:card_zombified_piglin",
        "minecards:card_ghast",
        "minecards:card_magma_cube",
        "minecards:card_blaze",
        "minecards:card_nether_fortress",
        "minecards:card_wither",
        "minecards:card_set_end",
        "minecards:card_the_end",
        "minecards:card_endstone",
        "minecards:card_obsidian",
        "minecards:card_chorus_plant",
        "minecards:card_end_crystal",
        "minecards:card_eye_of_ender",
        "minecards:card_elytra",
        "minecards:card_stronghold",
        "minecards:card_end_city",
        "minecards:card_enderman",
        "minecards:card_shulker",
        "minecards:card_ender_dragon",
        "minecards:card_set_aquatic",
        "minecards:card_squid",
        "minecards:card_dolphin",
        "minecards:card_turtle",
        "minecards:card_coral",
        "minecards:card_salmon",
        "minecards:card_pufferfish",
        "minecards:card_guardian",
        "minecards:card_elder_guardian",
        "minecards:card_fishing_rod",
        "minecards:card_kelp",
        "minecards:card_sponge",
        "minecards:card_ocean_monument",
        "minecards:card_set_deep_and_dark",
        "minecards:card_deepslate",
        "minecards:card_glow_berry",
        "minecards:card_dripleaf",
        "minecards:card_sculk",
        "minecards:card_glow_squid",
        "minecards:card_sculk_shrieker",
        "minecards:card_echo_shard",
        "minecards:card_lush_caves",
        "minecards:card_dripstone_caves",
        "minecards:card_deep_dark",
        "minecards:card_warden",
        "minecards:card_ancient_city",
        "minecards:card_set_retro",
        "minecards:card_cobblestone",
        "minecards:card_gravel",
        "minecards:card_rose",
        "minecards:card_cyan_flower",
        "minecards:card_nether_reactor_core",
        "minecards:card_cow_token",
        "minecards:card_sheep_token",
        "minecards:card_zombie_token",
        "minecards:card_skeleton_token",
        "minecards:card_creeper_token",
        "minecards:card_human",
        "minecards:card_testificate",
        "minecards:card_brick_pyramid",
        "minecards:card_feather",
        "minecards:card_disc_eleven",
        "minecards:card_herobrine",
        "minecards:card_the_far_lands",
        "minecards:card_enchanted_golden_apple",
        "minecards:card_set_village_and_pillage",
        "minecards:card_emerald",
        "minecards:card_bell",
        "minecards:card_villager",
        "minecards:card_iron_golem",
        "minecards:card_pillager",
        "minecards:card_vindicator",
        "minecards:card_ravager",
        "minecards:card_evoker",
        "minecards:card_illusioner",
        "minecards:card_raid",
        "minecards:card_village",
        "minecards:card_woodland_mansion",
        "minecards:card_ace_of_diamonds",
        "minecards:card_forge",
        "minecards:card_rules_card",
        "minecards:card_blank_card",
        "minecards:card_logo",
        "minecards:golden_card_set_overworld",
        "minecards:golden_card_set_nether",
        "minecards:golden_card_set_end",
        "minecards:golden_card_set_aquatic",
        "minecards:golden_card_set_retro",
        "minecards:golden_card_set_deep_and_dark",
        "minecards:golden_card_set_village_and_pillage"
        
    ]

    let mineCardsQuality = [
        "poor",
        "fair",
        "great",
        "mint"
    ]
    
    // Card Foil Recipe

    mineCardsList.forEach((card) => {

        mineCardsQuality.forEach((quality) => {

            event.recipes.create.compacting(
                Item.of(`${card}`, `{Foil:1,Quality:"${quality}"}`),
                [Item.of(`${card}`, `{Foil:0,Quality:"${quality}"}`).strongNBT(), "alexscaves:polymer_plate", Fluid.of("create_dd:shimmer", 1000)]
            ).superheated();

    });

  });


  mineCardsList.forEach((card) => {
  // Card Upgrade Recipe Poor-to-Fair
    event.custom({
      type: "create_new_age:energising",
      energy_needed: 100000,
      ingredients: [
        Item.of(`${card}`, '{Foil:0, Quality:"poor"}').strongNBT()
      ],
      results: [
          Item.of(`${card}`, '{Foil:0, Quality:"fair"}')      
      ]
    });

    event.custom({
      type: "create_new_age:energising",
      energy_needed: 100000,
      ingredients: [
        Item.of(`${card}`, '{Foil:1, Quality:"poor"}').strongNBT()
      ],
      results: [
          Item.of(`${card}`, '{Foil:1, Quality:"fair"}')      
      ]
    });


  // Card Upgrade Recipe Fair-to-Great
  event.custom({
    type: "alexscaves:nuclear_furnace",
    ingredient: Item.of(`${card}`, '{Foil:0, Quality:"fair"}').strongNBT(),
    result: Item.of(`${card}`, '{Foil:0, Quality:"great"}'),
    experience: 0.7,
    cookingtime: 1000,
  });

  event.custom({
    type: "alexscaves:nuclear_furnace",
    ingredient: Item.of(`${card}`, '{Foil:1, Quality:"fair"}').strongNBT(),
    result: Item.of(`${card}`, '{Foil:1, Quality:"great"}'),
    experience: 0.7,
    cookingtime: 1000,
  });

  
  // Card Upgrade Recipe Great-to-Mint
  event.custom({
      type: "createdieselgenerators:bulk_fermenting",
      ingredients: [
        Item.of(`${card}`, '{Foil:0, Quality:"great"}').strongNBT(),
        {
            fluid: "create_enchantment_industry:hyper_experience",
            amount: 250
        }
      ],
      heatRequirement: "heated",
      processingTime: 300,
      results: [
        Item.of(`${card}`, '{Foil:0, Quality:"mint"}')
      ]
    }); 

  event.custom({
      type: "createdieselgenerators:bulk_fermenting",
      ingredients: [
        Item.of(`${card}`, '{Foil:1, Quality:"great"}').strongNBT(),
        {
            fluid: "create_enchantment_industry:hyper_experience",
            amount: 250
        }
      ],
      heatRequirement: "heated",
      processingTime: 300,
      results: [
        Item.of(`${card}`, '{Foil:1, Quality:"mint"}')
      ]
    }); 

    });












});