StartupEvents.registry('item', e => {
  Platform.mods.kubejs.name = 'Society'

  e.create('society:iron_sea_coin').texture('society:item/iron_sea_coin')
  e.create('society:gold_sea_coin').texture('society:item/gold_sea_coin')
  e.create('society:neptunium_sea_coin').texture('society:item/neptunium_sea_coin').glow(true)
  e.create('society:unholy_contract').texture('society:item/unholy_contract')
  e.create('society:gourmand_contract').texture('society:item/gourmand_contract')
  e.create('society:aquamagical_dust').texture('society:item/aquamagical_dust').glow(true)
  e.create('society:aquamagical_essence').texture('society:item/aquamagical_essence').glow(true)
  e.create('society:aquamagical_crystal').texture('society:item/aquamagical_crystal').glow(true)
  e.create('society:sea_coin_fragments').texture('society:item/sea_coin_fragments')
  e.create('herbalbrews:water_cup').texture('society:item/water_cup').maxStackSize(16)
  
  e.create('aquaculture:neptuna').food(food => {
    food
      .hunger(20)
      .saturation(2)
      .meat()
  }).texture('society:item/neptuna').glow(true)

  // Chum
  e.create("society:bucket_of_black_tiger_shrimp_chum").texture("society:item/bucket_of_black_tiger_shrimp_chum").unstackable().maxDamage(18);
  e.create("society:bucket_of_thrasher_chum").texture("society:item/bucket_of_thrasher_chum").unstackable().maxDamage(18);
  e.create("society:bucket_of_book_chum").texture("society:item/bucket_of_book_chum").unstackable().maxDamage(9);
  e.create("society:bucket_of_meat_chum").texture("society:item/bucket_of_meat_chum").unstackable().maxDamage(18);
})

StartupEvents.registry('fluid', e => {
  e.create("aquaculture:molten_neptunium")
    .thickTexture(0x17f4b8)
    .bucketColor(0x17f4b8)
    .displayName("Molten Neptunium")
    .tag("aquaculture:molten_neptunium");

  e.create("biomancy:blood")
    .thickTexture(0x99130c)
    .bucketColor(0x99130c)
    .displayName("Blood")
    .tag("biomancy:blood");
})

ItemEvents.modification(e => {
  e.modify('minecraft:flint_and_steel', item => {
    item.maxDamage = -1
  })
  e.modify("biomancy:despoil_sickle", (item) => {
    item.maxDamage = 3000;
  });
  e.modify('society:aquamagical_dust', item => {
    item.rarity = 'rare';
  });
  e.modify('society:aquamagical_essence', item => {
    item.rarity = 'rare';
  });
  e.modify('society:aquamagical_crystal', item => {
    item.rarity = 'rare';
  });
})
