//despoil loot table
ServerEvents.recipes(event => {
  const randomItems = [
    'biomancy:flesh_bits',
    'biomancy:tough_fibers',
    'biomancy:volatile_gland',
    'biomancy:toxin_gland',
    'biomancy:mob_gland',
    'biomancy:mob_marrow',
    'biomancy:mob_sinew',
    'biomancy:elastic_fibers',
    'biomancy:mob_claw',
    'biomancy:mob_fang',
    'biomancy:bone_fragments'
  ];

  //flesh blocks
  const fleshBlocks = [
    'biomancy:malignant_flesh',
    'biomesoplenty:flesh'
  ];

  fleshBlocks.forEach(flesh => {
    event.shapeless('biomancy:flesh_bits', [ 'biomancy:despoil_sickle', flesh ])
      .damageIngredient('biomancy:despoil_sickle', 1) 
      .modifyResult((grid, result) => {
        return Item.of(randomItems[Math.floor(Math.random() * randomItems.length)]);
      });
  });
});