use of gregtech.api.unification.material.properties.WireProperties in project GregTech by GregTechCEu.
the class ItemBlockCable method addInformation.
@Override
@SideOnly(Side.CLIENT)
public void addInformation(@Nonnull ItemStack stack, @Nullable World worldIn, @Nonnull List<String> tooltip, @Nonnull ITooltipFlag flagIn) {
WireProperties wireProperties = blockPipe.createItemProperties(stack);
int tier = GTUtility.getTierByVoltage(wireProperties.getVoltage());
if (wireProperties.isSuperconductor())
tooltip.add(I18n.format("gregtech.cable.superconductor", GTValues.VN[tier]));
tooltip.add(I18n.format("gregtech.cable.voltage", wireProperties.getVoltage(), GTValues.VNF[tier]));
tooltip.add(I18n.format("gregtech.cable.amperage", wireProperties.getAmperage()));
tooltip.add(I18n.format("gregtech.cable.loss_per_block", wireProperties.getLossPerBlock()));
if (flagIn.isAdvanced()) {
tooltip.add("MetaItem Id: " + ((BlockMaterialPipe<?, ?, ?>) blockPipe).getPrefix().name + ((BlockMaterialPipe<?, ?, ?>) blockPipe).getItemMaterial(stack).toCamelCaseString());
}
}
Aggregations