const modifyLeafLootByBlockID = [
  "ad_astra:glacian_leaves",
  "alexscaves:ancient_leaves",
  "deeperdarker:echo_leaves",
  "ecologics:coconut_leaves",
  "ecologics:walnut_leaves",
  "minecraft:acacia_leaves",
  "minecraft:azalea_leaves",
  "minecraft:birch_leaves",
  "minecraft:cherry_leaves",
  "minecraft:dark_oak_leaves",
  "minecraft:flowering_azalea_leaves",
  "minecraft:jungle_leaves",
  "minecraft:mangrove_leaves",
  "minecraft:oak_leaves",
  "minecraft:spruce_leaves",
  "nethers_exoticism:kiwano_leaves",
  "snifferplus:stone_pine_leaves",
  "thermal:rubberwood_leaves",
  "undergarden:grongle_leaves",
  "undergarden:smogstem_leaves",
  "undergarden:wigglewood_leaves",
];

LootJS.modifiers((event) => {
  modifyLeafLootByBlockID.forEach((leaf) => {
    event
      .addBlockLootModifier(leaf)
      .removeLoot("minecraft:stick")
      .randomChance(0.15)
      .addLoot("twigs:twig");
  });

  event
    .addBlockLootModifier("minecraft:dead_bush")
    .replaceLoot("minecraft:stick", "twigs:twig", true);
});
