Hey all, I'm sure I missed something simple, but I'm trying to create a a custom potion that acts like multiple Vanilla potions combined together. In this example, I'm trying to create a potion that acts like a Slowness, Mining Fatigue, and Health Boost potion all in one.
The Slowness and Health Boost attributes get modified correctly when the effect is given to the player, however, the Mining Fatigue attribute seems to remain unchanged, and I cannot figure out why. Any and all help is appreciated. Many thanks!
public class PotionExample extends Potion {
public PotionExample(boolean isBadEffect, int liquidColor){
super(isBadEffect, liquidColor);
this.registerPotionAttributeModifier(SharedMonsterAttributes.ATTACK_SPEED, MathHelper.getRandomUUID().toString(), -3.0D, 2);
this.registerPotionAttributeModifier(SharedMonsterAttributes.MOVEMENT_SPEED, MathHelper.getRandomUUID().toString(), -0.5D, 2);
this.registerPotionAttributeModifier(SharedMonsterAttributes.MAX_HEALTH, MathHelper.getRandomUUID().toString(), 4.0D, 0);
}
@Override
public void performEffect(EntityLivingBase entityLivingBase, int amplifier) {
super.performEffect(entityLivingBase, amplifier);
}
@Override
public boolean isReady(int duration, int amplifier) {
return true;
}
}