const MAIN_LEAD_INGOT = 'mekanism:ingot_lead'

const DUPLICATES_LEAD_INGOTS = [
  'immersiveengineering:ingot_lead',
  'geolosys:lead_ingot'
]


onEvent('recipes', event => {
  DUPLICATES_LEAD_INGOTS.forEach(item => {
    event.remove({ output: item })
    event.remove({ input: item })
  })
})


onEvent('tags.items', event => {
  DUPLICATES_LEAD_INGOTS.forEach(item => {
    event.removeAllTagsFrom(item)
  })

  event.add('forge:ingots/lead', MAIN_LEAD_INGOT)
})


onEvent('entity.drops', event => {
  event.drops.removeIf(drop => {
    return DUPLICATES_LEAD_INGOTS.includes(drop.item.id)
  })
})