Skip to content

Commit

Permalink
feat(despoil-loot): don't drop flesh bits from mobs
Browse files Browse the repository at this point in the history
  • Loading branch information
Elenterius committed Jun 16, 2023
1 parent 6360ec9 commit 5619bc2
Showing 1 changed file with 0 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@
import it.unimi.dsi.fastutil.objects.ObjectArrayList;
import net.minecraft.advancements.critereon.EntityFlagsPredicate;
import net.minecraft.advancements.critereon.EntityPredicate;
import net.minecraft.util.RandomSource;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.entity.LivingEntity;
import net.minecraft.world.entity.MobType;
import net.minecraft.world.entity.monster.warden.Warden;
import net.minecraft.world.item.Item;
import net.minecraft.world.item.ItemStack;
Expand Down Expand Up @@ -48,7 +46,6 @@ public class DespoilLootModifier extends LootModifier {
private static final ItemLoot GENERIC_GLAND = new ItemLoot(ModItems.GENERIC_MOB_GLAND, CONSTANT_ITEM_AMOUNT_FUNC);
private static final ItemLoot BONE_MARROW = new ItemLoot(ModItems.MOB_MARROW, RANDOM_ITEM_AMOUNT_FUNC_2);
private static final ItemLoot WITHERED_BONE_MARROW = new ItemLoot(ModItems.WITHERED_MOB_MARROW, RANDOM_ITEM_AMOUNT_FUNC_2);
private static final ItemLoot FLESH_BITS = new ItemLoot(ModItems.FLESH_BITS, RANDOM_ITEM_AMOUNT_FUNC_2); //bonus drop for bone cleaver
private static final ItemLoot ECHO_SHARD = new ItemLoot(() -> Items.ECHO_SHARD, RANDOM_ITEM_AMOUNT_FUNC_1);
private static final ItemLoot EMPTY = new ItemLoot(() -> Items.AIR, CONSTANT_ITEM_AMOUNT_FUNC);

Expand Down Expand Up @@ -124,12 +121,6 @@ protected DynamicLootTable buildLootTable(LivingEntity livingEntity) {
lootTable.add(ECHO_SHARD, 10);
}

if (livingEntity.getMobType() != MobType.UNDEAD) {
lootTable.add(FLESH_BITS, 15); //bonus
}

lootTable.add(EMPTY, 15);

return lootTable;
}

Expand Down

0 comments on commit 5619bc2

Please sign in to comment.