// kubejs/server_scripts/geore_block_empowering.js
ServerEvents.recipes(event => {
  // Empowerer: Amethyst Block (center) + 4x Essence (stands) -> GeOre Block

  const ENERGY = 2000
  const TIME = 100
  const COLOR = 0xFFFFFF

  const CENTER = "minecraft:amethyst_block"

  function empowerGeoreBlock(ore, essenceId) {
    const outBlock = `geore:${ore}_block`

    event.recipes.actuallyadditions
      .empowering(
        Item.of(outBlock),
        CENTER,
        [essenceId, essenceId, essenceId, essenceId]
      )
      .energy(ENERGY)
      .time(TIME)
      .color(COLOR)
  }

  empowerGeoreBlock("copper",  "mysticalagriculture:copper_essence")
  empowerGeoreBlock("gold",    "mysticalagriculture:gold_essence")
  empowerGeoreBlock("emerald", "mysticalagriculture:emerald_essence")
  empowerGeoreBlock("nickel",  "mysticalagriculture:nickel_essence")
  empowerGeoreBlock("iron",    "mysticalagriculture:iron_essence")
  empowerGeoreBlock("redstone","mysticalagriculture:redstone_essence")
  empowerGeoreBlock("coal",    "mysticalagriculture:coal_essence")
  empowerGeoreBlock("lapis",   "mysticalagriculture:lapis_lazuli_essence")
  empowerGeoreBlock("quartz",  "mysticalagriculture:nether_quartz_essence")
})

