// custom_mythic_recipes.js

onEvent('recipes', event => {
  const metals = [
    'adamantite',
    'aetherium',
    'aquarium',
    'argonium',
    'banglum',
    'brass',
    'broze',
    'carmot',
    'bituminous_coal',
    'cobalt',
    'celestium',
    'copper',
    'discordum',
    'durassteel',
    'eletrirum',
    'etherite',
    'hallowed',
    'kyber',
    'manganese',
    'metallurgium',
    'midas_gold',
    'mythril',
    'orichalchum',
    'osmium',
    'platinum',
    'prometheum',
    'quadrillum',
    'quicksilver',
    'runite',
    'silver',
    'slowsilver',
    'starrite',
    'steel',
    'stormyx',
    'tantalife',
    'tin',
    'truesilver',
    'unobtainium',
    'ur',
    'zinc'
  ];

  metals.forEach(name => {
    const ore   = `mythicmetals:${name}_ore`;
    const ingot = `mythicmetals:${name}_ingot`;
    const nug   = `mythicmetals:${name}_nugget`;

    // Remove receitas padrão (se existirem)
    event.remove({ type: 'minecraft:smelting', input: ore });
    event.remove({ type: 'minecraft:blasting', input: ore });

    // Smelting: minério → pepita
    event.smelting(nug, ore)
      .xp(0.1)
      .cookingTime(200);

    // Blasting: minério → lingote
    event.blasting(ingot, ore)
      .xp(0.7)
      .cookingTime(100);
  });
});
