public class PeridotArmor extends ArmorItem{
public PeridotArmor(IArmorMaterial materialIn, EquipmentSlotType slot, Properties builder) {
super(materialIn, slot, builder);
}
@Override
public void onArmorTick(ItemStack itemStack, World world, PlayerEntity player) {
ItemStack boots = player.getItemStackFromSlot(EquipmentSlotType.FEET);
if(boots.getItem() == ItemListOld.peridot_boots) {
if(!world.isRemote) {
player.addPotionEffect(new EffectInstance(Effects.SPEED, 5, 4, false, false, true));
}
}
}
}
I updated my code, but it seemed to unfortunately have no effect.
I tried swapping the order of the IF statements and adding/removing the booleans