newEffects.appendTag(new PotionEffect(effectID, packet.readInt(), packet.readUByte()).writeCustomPotionEffectToNBT(new NBTTagCompound()));
potion.getTagCompound().setTag("CustomPotionEffects", newEffects);
}
public void setPotionEffect(int effectID, int duration, int amplifier) {
PacketCustom packet = NEICPH.createContainerPacket();
packet.writeBoolean(true);
packet.writeByte(effectID);
packet.writeInt(duration);
packet.writeByte(amplifier);
packet.sendToServer();
}