public record ApplyExhaustion(LevelBasedValue amount) implements EnchantmentEntityEffect {
13
public static final MapCodec<ApplyExhaustion> CODEC = RecordCodecBuilder.mapCodec(
14
i -> i.group(LevelBasedValue.CODEC.fieldOf("amount").forGetter(ApplyExhaustion::amount)).apply(i, ApplyExhaustion::new)
15
);
16
17
@Override
18
public void apply(final ServerLevel serverLevel, final int enchantmentLevel, final EnchantedItemInUse item, final Entity entity, final Vec3 position) {
Decompiled Minecraft 26.3 source of ApplyExhaustion (net/minecraft/world/item/enchantment/effects/ApplyExhaustion.java) with Mojang official mappings, stored verbatim on the site.