diff --git a/src/main/java/gregtech/GT_Mod.java b/src/main/java/gregtech/GT_Mod.java index 848791bb..36975ced 100644 --- a/src/main/java/gregtech/GT_Mod.java +++ b/src/main/java/gregtech/GT_Mod.java @@ -316,6 +316,10 @@ public class GT_Mod implements IGT_Mod { GT_Log.out.println("GT_Mod: Generating Lang-File"); GT_LanguageManager.sEnglishFile = new Configuration(new File(aEvent.getModConfigurationDirectory().getParentFile(), "GregTech.lang")); GT_LanguageManager.sEnglishFile.load(); + for (Materials aMaterial : Materials.values()) { + if (aMaterial != null) + aMaterial.mLocalizedName = GT_LanguageManager.addStringLocalization("Material." + aMaterial.mName.toLowerCase(), aMaterial.mDefaultLocalName); + } GT_Log.out.println("GT_Mod: Removing all original Scrapbox Drops."); try { diff --git a/src/main/java/gregtech/api/enums/Materials.java b/src/main/java/gregtech/api/enums/Materials.java index 599cc60f..de1973a8 100644 --- a/src/main/java/gregtech/api/enums/Materials.java +++ b/src/main/java/gregtech/api/enums/Materials.java @@ -818,7 +818,7 @@ public class Materials implements IColorModulationContainer, ISubTagContainer { public byte mEnchantmentToolsLevel = 0, mEnchantmentArmorsLevel = 0; public boolean mBlastFurnaceRequired = false, mTransparent = false; public float mToolSpeed = 1.0F, mHeatDamage = 0.0F; - public String mChemicalFormula = "?", mName = "null", mDefaultLocalName = "null", mCustomID = "null", mConfigSection = "null"; + public String mChemicalFormula = "?", mName = "null", mDefaultLocalName = "null", mCustomID = "null", mConfigSection = "null", mLocalizedName = "null"; public Dyes mColor = Dyes._NULL; public short mMeltingPoint = 0, mBlastFurnaceTemp = 0, mGasTemp = 0; public int mTypes = 0; @@ -1984,6 +1984,19 @@ public class Materials implements IColorModulationContainer, ISubTagContainer { return new GT_FluidStack(mStandardMoltenFluid, (int) aAmount); } + public String getLocalizedNameForItem(String aFormat) { + return String.format(aFormat.replace("%s", "%temp").replace("%material", "%s"), this.mLocalizedName).replace("%temp", "%s"); + } + + public static String getLocalizedNameForItem(String aFormat, int aMaterialID) { + if (aMaterialID >= 0 && aMaterialID < 1000) { + Materials aMaterial = GregTech_API.sGeneratedMaterials[aMaterialID]; + if (aMaterial != null) + return aMaterial.getLocalizedNameForItem(aFormat); + } + return aFormat; + } + @Override public short[] getRGBA() { return mRGBa; diff --git a/src/main/java/gregtech/api/enums/OrePrefixes.java b/src/main/java/gregtech/api/enums/OrePrefixes.java index ecc6d946..7381e10a 100644 --- a/src/main/java/gregtech/api/enums/OrePrefixes.java +++ b/src/main/java/gregtech/api/enums/OrePrefixes.java @@ -898,26 +898,31 @@ public enum OrePrefixes { return name() + aMaterial; } - @SuppressWarnings("incomplete-switch") + @Deprecated public String getDefaultLocalNameForItem(Materials aMaterial) { + return aMaterial.getLocalizedNameForItem(getDefaultLocalNameFormatForItem(aMaterial)); + } + + @SuppressWarnings("incomplete-switch") + public String getDefaultLocalNameFormatForItem(Materials aMaterial) { // Certain Materials have slightly different Localizations. switch (this) { case crateGtDust: - return mLocalizedMaterialPre + OrePrefixes.dust.getDefaultLocalNameForItem(aMaterial); + return mLocalizedMaterialPre + OrePrefixes.dust.getDefaultLocalNameFormatForItem(aMaterial); case crateGtIngot: - return mLocalizedMaterialPre + OrePrefixes.ingot.getDefaultLocalNameForItem(aMaterial); + return mLocalizedMaterialPre + OrePrefixes.ingot.getDefaultLocalNameFormatForItem(aMaterial); case crateGtGem: - return mLocalizedMaterialPre + OrePrefixes.gem.getDefaultLocalNameForItem(aMaterial); + return mLocalizedMaterialPre + OrePrefixes.gem.getDefaultLocalNameFormatForItem(aMaterial); case crateGtPlate: - return mLocalizedMaterialPre + OrePrefixes.plate.getDefaultLocalNameForItem(aMaterial); + return mLocalizedMaterialPre + OrePrefixes.plate.getDefaultLocalNameFormatForItem(aMaterial); } switch (aMaterial.mName) { case "Glass": case "BorosilicateGlass": - if (name().startsWith("gem")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Crystal"; - if (name().startsWith("plate")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Pane"; - if (name().startsWith("ingot")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Bar"; - if (name().startsWith("nugget")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Chip"; + if (name().startsWith("gem")) return mLocalizedMaterialPre + "%material" + " Crystal"; + if (name().startsWith("plate")) return mLocalizedMaterialPre + "%material" + " Pane"; + if (name().startsWith("ingot")) return mLocalizedMaterialPre + "%material" + " Bar"; + if (name().startsWith("nugget")) return mLocalizedMaterialPre + "%material" + " Chip"; break; case "Wheat": if (name().startsWith("dust")) return mLocalizedMaterialPre + "Flour"; @@ -927,11 +932,11 @@ public enum OrePrefixes { break; case "Wood": case "WoodSealed": - if (name().startsWith("bolt")) return "Short " + aMaterial.mDefaultLocalName + " Stick"; - if (name().startsWith("stick")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Stick"; - if (name().startsWith("dust")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Pulp"; - if (name().startsWith("nugget")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Chip"; - if (name().startsWith("plate")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Plank"; + if (name().startsWith("bolt")) return "Short " + "%material" + " Stick"; + if (name().startsWith("stick")) return mLocalizedMaterialPre + "%material" + " Stick"; + if (name().startsWith("dust")) return mLocalizedMaterialPre + "%material" + " Pulp"; + if (name().startsWith("nugget")) return mLocalizedMaterialPre + "%material" + " Chip"; + if (name().startsWith("plate")) return mLocalizedMaterialPre + "%material" + " Plank"; break; case "Plastic": case "Rubber": @@ -946,17 +951,17 @@ public enum OrePrefixes { case "PolyvinylChloride": case "Polystyrene": case "StyreneButadieneRubber": - if (name().startsWith("dust")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Pulp"; - if (name().startsWith("plate")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Sheet"; - if (name().startsWith("ingot")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Bar"; - if (name().startsWith("nugget")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Chip"; - if (name().startsWith("foil")) return "Thin " + aMaterial.mDefaultLocalName + " Sheet"; + if (name().startsWith("dust")) return mLocalizedMaterialPre + "%material" + " Pulp"; + if (name().startsWith("plate")) return mLocalizedMaterialPre + "%material" + " Sheet"; + if (name().startsWith("ingot")) return mLocalizedMaterialPre + "%material" + " Bar"; + if (name().startsWith("nugget")) return mLocalizedMaterialPre + "%material" + " Chip"; + if (name().startsWith("foil")) return "Thin " + "%material" + " Sheet"; break; case "FierySteel": if (mIsContainer) return mLocalizedMaterialPre + "Fiery Blood" + mLocalizedMaterialPost; break; case "Steeleaf": - if (name().startsWith("ingot")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName; + if (name().startsWith("ingot")) return mLocalizedMaterialPre + "%material"; break; case "Bone": if (name().startsWith("dust")) return mLocalizedMaterialPre + "Bone Meal"; @@ -969,7 +974,7 @@ public enum OrePrefixes { case "Chili": case "Cheese": case "Snow": - if (name().startsWith("dust")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Powder"; + if (name().startsWith("dust")) return mLocalizedMaterialPre + "%material" + " Powder"; break; case "Paper": if (name().startsWith("dust")) return mLocalizedMaterialPre + "Chad"; @@ -996,7 +1001,7 @@ public enum OrePrefixes { case "RockSalt": case "VolcanicAsh": case "RareEarth": - if (name().startsWith("dust")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName; + if (name().startsWith("dust")) return mLocalizedMaterialPre + "%material"; break; case "Vermiculite": case "Bentonite": @@ -1010,13 +1015,13 @@ public enum OrePrefixes { case "QuartzSand": case "Pitchblende": case "FullersEarth": - if (name().startsWith("dust")) return mLocalizedMaterialPre + aMaterial.mDefaultLocalName; + if (name().startsWith("dust")) return mLocalizedMaterialPre + "%material"; switch (this) { case crushedCentrifuged: case crushedPurified: - return mLocalizedMaterialPre + aMaterial.mDefaultLocalName; + return mLocalizedMaterialPre + "%material"; case crushed: - return "Ground " + aMaterial.mDefaultLocalName; + return "Ground " + "%material"; } break; } @@ -1030,22 +1035,22 @@ public enum OrePrefixes { case "InfusedOrder": case "InfusedVis": case "InfusedWater": - if (name().startsWith("gem")) return mLocalizedMaterialPre + "Shard of " + aMaterial.mDefaultLocalName; - if (name().startsWith("crystal")) return mLocalizedMaterialPre + "Shard of " + aMaterial.mDefaultLocalName; + if (name().startsWith("gem")) return mLocalizedMaterialPre + "Shard of " + "%material"; + if (name().startsWith("crystal")) return mLocalizedMaterialPre + "Shard of " + "%material"; if (name().startsWith("plate")) - return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Crystal Plate"; + return mLocalizedMaterialPre + "%material" + " Crystal Plate"; if (name().startsWith("dust")) - return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Crystal Powder"; + return mLocalizedMaterialPre + "%material" + " Crystal Powder"; switch (this) { case crushedCentrifuged: case crushedPurified: case crushed: - return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + " Crystals"; + return mLocalizedMaterialPre + "%material" + " Crystals"; } break; } } // Use Standard Localization - return mLocalizedMaterialPre + aMaterial.mDefaultLocalName + mLocalizedMaterialPost; + return mLocalizedMaterialPre + "%material" + mLocalizedMaterialPost; } } \ No newline at end of file diff --git a/src/main/java/gregtech/api/items/GT_CoolantCell_Item.java b/src/main/java/gregtech/api/items/GT_CoolantCell_Item.java index 5a94d3b4..980967e5 100644 --- a/src/main/java/gregtech/api/items/GT_CoolantCell_Item.java +++ b/src/main/java/gregtech/api/items/GT_CoolantCell_Item.java @@ -5,6 +5,7 @@ import ic2.core.util.StackUtil; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.EnumChatFormatting; import net.minecraft.util.StatCollector; import java.util.List; @@ -50,7 +51,21 @@ public class GT_CoolantCell_Item public void addAdditionalToolTips(List aList, ItemStack aStack, EntityPlayer aPlayer) { super.addAdditionalToolTips(aList, aStack, aPlayer); - aList.add("Stored Heat: " + getHeatOfStack(aStack)); + int rHeat = getHeatOfStack(aStack) * 10 / this.heatStorage; + EnumChatFormatting color; + switch (rHeat) { + case 0: color = EnumChatFormatting.BLUE; break; + case 1: + case 2: color = EnumChatFormatting.GREEN; break; + case 3: + case 4: + case 5: + case 6: color = EnumChatFormatting.YELLOW; break; + case 7: + case 8: color = EnumChatFormatting.RED; break; + default: color = EnumChatFormatting.DARK_RED; break; + } + aList.add(EnumChatFormatting.WHITE + String.format(trans("000", "Stored Heat: %s"), "" + color + getHeatOfStack(aStack))); switch (getControlTagOfStack(aStack)) { case 1: aList.add(StatCollector.translateToLocal("ic2.reactoritem.heatwarning.line1")); diff --git a/src/main/java/gregtech/api/items/GT_Generic_Item.java b/src/main/java/gregtech/api/items/GT_Generic_Item.java index 42827018..73102711 100644 --- a/src/main/java/gregtech/api/items/GT_Generic_Item.java +++ b/src/main/java/gregtech/api/items/GT_Generic_Item.java @@ -155,4 +155,8 @@ public class GT_Generic_Item extends Item implements IProjectileItem { return null; } } + + public String trans(String aKey, String aEnglish){ + return GT_LanguageManager.addStringLocalization("Item_DESCRIPTION_Index_"+aKey, aEnglish, false); + } } \ No newline at end of file diff --git a/src/main/java/gregtech/api/items/GT_MetaBase_Item.java b/src/main/java/gregtech/api/items/GT_MetaBase_Item.java index 237b15fa..c4203c77 100644 --- a/src/main/java/gregtech/api/items/GT_MetaBase_Item.java +++ b/src/main/java/gregtech/api/items/GT_MetaBase_Item.java @@ -198,13 +198,13 @@ public abstract class GT_MetaBase_Item extends GT_Generic_Item implements ISpeci tStats = getElectricStats(aStack); if (tStats != null) { if (tStats[3] > 0) { - aList.add(EnumChatFormatting.AQUA + "Contains " + GT_Utility.formatNumbers(tStats[3]) + " EU Tier: " + (tStats[2] >= 0 ? tStats[2] : 0) + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.AQUA + String.format(trans("009", "Contains %s EU Tier: %s"), GT_Utility.formatNumbers(tStats[3]), "" + (tStats[2] >= 0 ? tStats[2] : 0)) + EnumChatFormatting.GRAY); } else { long tCharge = getRealCharge(aStack); if (tStats[3] == -2 && tCharge <= 0) { - aList.add(EnumChatFormatting.AQUA + "Empty. You should recycle it properly." + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.AQUA + trans("010", "Empty. You should recycle it properly.") + EnumChatFormatting.GRAY); } else { - aList.add(String.valueOf(EnumChatFormatting.AQUA) + GT_Utility.formatNumbers(tCharge) + " / " + GT_Utility.formatNumbers(Math.abs(tStats[0])) + " EU - Voltage: " + V[(int) (tStats[2] >= 0 ? tStats[2] < V.length ? tStats[2] : V.length - 1 : 1)] + EnumChatFormatting.GRAY); + aList.add(String.valueOf(EnumChatFormatting.AQUA) + String.format(trans("011", "%s / %s EU - Voltage: %s"), GT_Utility.formatNumbers(tCharge), GT_Utility.formatNumbers(Math.abs(tStats[0])), "" + V[(int) (tStats[2] >= 0 ? tStats[2] < V.length ? tStats[2] : V.length - 1 : 1)]) + EnumChatFormatting.GRAY); } } } @@ -212,8 +212,8 @@ public abstract class GT_MetaBase_Item extends GT_Generic_Item implements ISpeci tStats = getFluidContainerStats(aStack); if (tStats != null && tStats[0] > 0) { FluidStack tFluid = getFluidContent(aStack); - aList.add(EnumChatFormatting.BLUE + ((tFluid == null ? "No Fluids Contained" : GT_Utility.getFluidName(tFluid, true))) + EnumChatFormatting.GRAY); - aList.add(EnumChatFormatting.BLUE + ((tFluid == null ? 0 : tFluid.amount) + "L / " + tStats[0] + "L") + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.BLUE + ((tFluid == null ? trans("012", "No Fluids Contained") : GT_Utility.getFluidName(tFluid, true))) + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.BLUE + String.format(trans("013", "%sL / %sL"), "" + (tFluid == null ? 0 : tFluid.amount), "" + tStats[0]) + EnumChatFormatting.GRAY); } ArrayList> tList = mItemBehaviors.get((short) getDamage(aStack)); diff --git a/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X01.java b/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X01.java index 74e50e86..a97613f5 100644 --- a/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X01.java +++ b/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X01.java @@ -54,7 +54,7 @@ public abstract class GT_MetaGenerated_Item_X01 extends GT_MetaGenerated_Item { if (tMaterial == null) continue; if (mPrefix.doGenerateItem(tMaterial)) { ItemStack tStack = new ItemStack(this, 1, i); - GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".name", getDefaultLocalization(tPrefix, tMaterial, i)); + GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".name", getDefaultLocalizationFormat(tPrefix, tMaterial, i)); GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".tooltip", tMaterial.getToolTip(tPrefix.mMaterialAmount / M)); String tOreName = getOreDictString(tPrefix, tMaterial); tPrefix = OrePrefixes.getOrePrefix(tOreName); @@ -75,10 +75,21 @@ public abstract class GT_MetaGenerated_Item_X01 extends GT_MetaGenerated_Item { * @param aMetaData a Index from [0 - 31999] * @return the Localized Name when default LangFiles are used. */ + @Deprecated public String getDefaultLocalization(OrePrefixes aPrefix, Materials aMaterial, int aMetaData) { return aPrefix.getDefaultLocalNameForItem(aMaterial); } + /** + * @param aPrefix the OreDict Prefix + * @param aMaterial the Material + * @param aMetaData a Index from [0 - 31999] + * @return the Localized Name Format when default LangFiles are used. + */ + public String getDefaultLocalizationFormat(OrePrefixes aPrefix, Materials aMaterial, int aMetaData) { + return aPrefix.getDefaultLocalNameFormatForItem(aMaterial); + } + /** * @param aPrefix always != null * @param aMaterial always != null @@ -102,6 +113,15 @@ public abstract class GT_MetaGenerated_Item_X01 extends GT_MetaGenerated_Item { /* ---------- INTERNAL OVERRIDES ---------- */ + @Override + public String getItemStackDisplayName(ItemStack aStack) { + String aName = super.getItemStackDisplayName(aStack); + int aDamage = getDamage(aStack); + if (aDamage < 32000 && aDamage >= 0) + return Materials.getLocalizedNameForItem(aName, aDamage % 1000); + return aName; + } + @Override public ItemStack getContainerItem(ItemStack aStack) { int aMetaData = aStack.getItemDamage(); diff --git a/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X32.java b/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X32.java index cadbe685..515735f8 100644 --- a/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X32.java +++ b/src/main/java/gregtech/api/items/GT_MetaGenerated_Item_X32.java @@ -52,7 +52,7 @@ public abstract class GT_MetaGenerated_Item_X32 extends GT_MetaGenerated_Item { if (tMaterial == null) continue; if (doesMaterialAllowGeneration(tPrefix, tMaterial)) { ItemStack tStack = new ItemStack(this, 1, i); - GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".name", getDefaultLocalization(tPrefix, tMaterial, i)); + GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".name", getDefaultLocalizationFormat(tPrefix, tMaterial, i)); GT_LanguageManager.addStringLocalization(getUnlocalizedName(tStack) + ".tooltip", tMaterial.getToolTip(tPrefix.mMaterialAmount / M)); if (tPrefix.mIsUnificatable) { GT_OreDictUnificator.set(tPrefix, tMaterial, tStack); @@ -96,10 +96,21 @@ public abstract class GT_MetaGenerated_Item_X32 extends GT_MetaGenerated_Item { * @param aMetaData a Index from [0 - 31999] * @return the Localized Name when default LangFiles are used. */ + @Deprecated public String getDefaultLocalization(OrePrefixes aPrefix, Materials aMaterial, int aMetaData) { return aPrefix.getDefaultLocalNameForItem(aMaterial); } + /** + * @param aPrefix the OreDict Prefix + * @param aMaterial the Material + * @param aMetaData a Index from [0 - 31999] + * @return the Localized Name Format when default LangFiles are used. + */ + public String getDefaultLocalizationFormat(OrePrefixes aPrefix, Materials aMaterial, int aMetaData) { + return aPrefix.getDefaultLocalNameFormatForItem(aMaterial); + } + /** * @param aMetaData a Index from [0 - 31999] * @param aMaterial the Material @@ -121,6 +132,15 @@ public abstract class GT_MetaGenerated_Item_X32 extends GT_MetaGenerated_Item { /* ---------- INTERNAL OVERRIDES ---------- */ + @Override + public String getItemStackDisplayName(ItemStack aStack) { + String aName = super.getItemStackDisplayName(aStack); + int aDamage = getDamage(aStack); + if (aDamage < 32000 && aDamage >= 0) + return Materials.getLocalizedNameForItem(aName, aDamage % 1000); + return aName; + } + @Override public ItemStack getContainerItem(ItemStack aStack) { int aDamage = aStack.getItemDamage(); diff --git a/src/main/java/gregtech/api/items/GT_MetaGenerated_Tool.java b/src/main/java/gregtech/api/items/GT_MetaGenerated_Tool.java index 9ce0e913..d8b09765 100644 --- a/src/main/java/gregtech/api/items/GT_MetaGenerated_Tool.java +++ b/src/main/java/gregtech/api/items/GT_MetaGenerated_Tool.java @@ -346,18 +346,18 @@ public abstract class GT_MetaGenerated_Tool extends GT_MetaBase_Item implements if (tStats != null) { String name = aStack.getUnlocalizedName(); if (name.equals("gt.metatool.01.170") || name.equals("gt.metatool.01.172") || name.equals("gt.metatool.01.174") || name.equals("gt.metatool.01.176")) { - aList.add(tOffset + 0, EnumChatFormatting.WHITE + "Durability: " + EnumChatFormatting.GREEN + (tMaxDamage - getToolDamage(aStack)) + " / " + tMaxDamage + EnumChatFormatting.GRAY); - aList.add(tOffset + 1, EnumChatFormatting.WHITE + tMaterial.mDefaultLocalName + EnumChatFormatting.YELLOW + " lvl " + getHarvestLevel(aStack, "") + EnumChatFormatting.GRAY); - aList.add(tOffset + 2, EnumChatFormatting.WHITE + "Turbine Efficiency: " + EnumChatFormatting.BLUE + (50.0F + (10.0F * getToolCombatDamage(aStack))) + EnumChatFormatting.GRAY); - aList.add(tOffset + 3, EnumChatFormatting.WHITE + "Optimal Steam flow: " + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 1000) + EnumChatFormatting.GRAY + "L/sec"); - aList.add(tOffset + 3, EnumChatFormatting.WHITE + "Optimal Gas flow(EU burnvalue per tick): " + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 50) + EnumChatFormatting.GRAY + "EU/t"); - aList.add(tOffset + 3, EnumChatFormatting.WHITE + "Optimal Plasma flow(Plasma energyvalue per tick): " + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 2000) + EnumChatFormatting.GRAY + "EU/t"); + aList.add(tOffset + 0, EnumChatFormatting.WHITE + String.format(trans("001", "Durability: %s/%s"), "" + EnumChatFormatting.GREEN + (tMaxDamage - getToolDamage(aStack)) + " ", " " + tMaxDamage) + EnumChatFormatting.GRAY); + aList.add(tOffset + 1, EnumChatFormatting.WHITE + String.format(trans("002", "%s lvl %s"), tMaterial.mLocalizedName + EnumChatFormatting.YELLOW, "" + getHarvestLevel(aStack, "")) + EnumChatFormatting.GRAY); + aList.add(tOffset + 2, EnumChatFormatting.WHITE + String.format(trans("005", "Turbine Efficiency: %s"), "" + EnumChatFormatting.BLUE + (50.0F + (10.0F * getToolCombatDamage(aStack)))) + EnumChatFormatting.GRAY); + aList.add(tOffset + 3, EnumChatFormatting.WHITE + String.format(trans("006", "Optimal Steam flow: %sL/sec"), "" + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 1000) + EnumChatFormatting.GRAY)); + aList.add(tOffset + 4, EnumChatFormatting.WHITE + String.format(trans("007", "Optimal Gas flow(EU burnvalue per tick): %sEU/t"), "" + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 50) + EnumChatFormatting.GRAY)); + aList.add(tOffset + 5, EnumChatFormatting.WHITE + String.format(trans("008", "Optimal Plasma flow(Plasma energyvalue per tick): %sEU/t"), "" + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed * 2000) + EnumChatFormatting.GRAY)); } else { - aList.add(tOffset + 0, EnumChatFormatting.WHITE + "Durability: " + EnumChatFormatting.GREEN + (tMaxDamage - getToolDamage(aStack)) + " / " + tMaxDamage + EnumChatFormatting.GRAY); - aList.add(tOffset + 1, EnumChatFormatting.WHITE + tMaterial.mDefaultLocalName + EnumChatFormatting.YELLOW + " lvl " + getHarvestLevel(aStack, "") + EnumChatFormatting.GRAY); - aList.add(tOffset + 2, EnumChatFormatting.WHITE + "Attack Damage: " + EnumChatFormatting.BLUE + getToolCombatDamage(aStack) + EnumChatFormatting.GRAY); - aList.add(tOffset + 3, EnumChatFormatting.WHITE + "Mining Speed: " + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed) + EnumChatFormatting.GRAY); + aList.add(tOffset + 0, EnumChatFormatting.WHITE + String.format(trans("001", "Durability: %s/%s"), "" + EnumChatFormatting.GREEN + (tMaxDamage - getToolDamage(aStack)) + " ", " " + tMaxDamage) + EnumChatFormatting.GRAY); + aList.add(tOffset + 1, EnumChatFormatting.WHITE + String.format(trans("002", "%s lvl %s"), tMaterial.mLocalizedName + EnumChatFormatting.YELLOW, "" + getHarvestLevel(aStack, "")) + EnumChatFormatting.GRAY); + aList.add(tOffset + 2, EnumChatFormatting.WHITE + String.format(trans("003", "Attack Damage: %s"), "" + EnumChatFormatting.BLUE + getToolCombatDamage(aStack)) + EnumChatFormatting.GRAY); + aList.add(tOffset + 3, EnumChatFormatting.WHITE + String.format(trans("004", "Mining Speed: %s"), "" + EnumChatFormatting.LIGHT_PURPLE + Math.max(Float.MIN_NORMAL, tStats.getSpeedMultiplier() * getPrimaryMaterial(aStack).mToolSpeed)) + EnumChatFormatting.GRAY); NBTTagCompound aNBT = aStack.getTagCompound(); if (aNBT != null) { aNBT = aNBT.getCompoundTag("GT.ToolStats"); diff --git a/src/main/java/gregtech/api/items/GT_RadioactiveCell_Item.java b/src/main/java/gregtech/api/items/GT_RadioactiveCell_Item.java index 082dab75..bf6ca2ae 100644 --- a/src/main/java/gregtech/api/items/GT_RadioactiveCell_Item.java +++ b/src/main/java/gregtech/api/items/GT_RadioactiveCell_Item.java @@ -5,9 +5,12 @@ import ic2.core.util.StackUtil; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemStack; import net.minecraft.nbt.NBTTagCompound; +import net.minecraft.util.EnumChatFormatting; import java.util.List; +import gregtech.common.items.GT_DepletetCell_Item; + public class GT_RadioactiveCell_Item extends GT_Generic_Item implements IBoxable{ protected int cellCount; @@ -139,7 +142,18 @@ public class GT_RadioactiveCell_Item public void addAdditionalToolTips(List aList, ItemStack aStack, EntityPlayer aPlayer) { super.addAdditionalToolTips(aList, aStack, aPlayer); //aList.add("Time left: " + (this.maxDelay - getDurabilityOfStack(aStack)) + " secs"); - aList.add("Durability: " + (this.maxDmg - getDurabilityOfStack(aStack)) + "/" + this.maxDmg); + int rDmg = getDurabilityOfStack(aStack) * 6 / this.maxDmg; + EnumChatFormatting color2; + switch (rDmg) { + case 0: + case 1: color2 = EnumChatFormatting.WHITE; break; + case 2: + case 3: + case 4: color2 = EnumChatFormatting.GRAY; break; + default: color2 = EnumChatFormatting.DARK_GRAY; break; + } + EnumChatFormatting color1 = this instanceof GT_DepletetCell_Item ? color2 = EnumChatFormatting.DARK_GRAY : EnumChatFormatting.WHITE; + aList.add(color1 + String.format(trans("001", "Durability: %s/%s"), "" + color2 + (this.maxDmg - getDurabilityOfStack(aStack)) + color1, "" + this.maxDmg)); } @Override diff --git a/src/main/java/gregtech/api/util/GT_LanguageManager.java b/src/main/java/gregtech/api/util/GT_LanguageManager.java index 59a24ef4..18c94320 100644 --- a/src/main/java/gregtech/api/util/GT_LanguageManager.java +++ b/src/main/java/gregtech/api/util/GT_LanguageManager.java @@ -317,7 +317,26 @@ public class GT_LanguageManager { // addStringLocalization("Interaction_DESCRIPTION_Index_209", "Grab"); // addStringLocalization("Interaction_DESCRIPTION_Index_210", "Grab"); addStringLocalization("Interaction_DESCRIPTION_Index_211", "Items per side: "); - + + addStringLocalization("Item_DESCRIPTION_Index_000", "Stored Heat: %s"); + addStringLocalization("Item_DESCRIPTION_Index_001", "Durability: %s/%s"); + addStringLocalization("Item_DESCRIPTION_Index_002", "%s lvl %s"); + addStringLocalization("Item_DESCRIPTION_Index_003", "Attack Damage: %s"); + addStringLocalization("Item_DESCRIPTION_Index_004", "Mining Speed: %s"); + addStringLocalization("Item_DESCRIPTION_Index_005", "Turbine Efficiency: %s"); + addStringLocalization("Item_DESCRIPTION_Index_006", "Optimal Steam flow: %sL/sec"); + addStringLocalization("Item_DESCRIPTION_Index_007", "Optimal Gas flow(EU burnvalue per tick): %sEU/t"); + addStringLocalization("Item_DESCRIPTION_Index_008", "Optimal Plasma flow(Plasma energyvalue per tick): %sEU/t"); + addStringLocalization("Item_DESCRIPTION_Index_009", "Contains %s EU Tier: %s"); + addStringLocalization("Item_DESCRIPTION_Index_010", "Empty. You should recycle it properly."); + addStringLocalization("Item_DESCRIPTION_Index_011", "%s / %s EU - Voltage: %s"); + addStringLocalization("Item_DESCRIPTION_Index_012", "No Fluids Contained"); + addStringLocalization("Item_DESCRIPTION_Index_013", "%sL / %sL"); + addStringLocalization("Item_DESCRIPTION_Index_014", "Missing Coodinates!"); + addStringLocalization("Item_DESCRIPTION_Index_015", "Device at:"); + addStringLocalization("Item_DESCRIPTION_Index_016", "Amount: %s L"); + addStringLocalization("Item_DESCRIPTION_Index_017", "Temperature: %s K"); + addStringLocalization("Item_DESCRIPTION_Index_018", "State: %s"); } } diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Metal.java b/src/main/java/gregtech/common/blocks/GT_Block_Metal.java index 2f54c9c4..ca27928b 100644 --- a/src/main/java/gregtech/common/blocks/GT_Block_Metal.java +++ b/src/main/java/gregtech/common/blocks/GT_Block_Metal.java @@ -25,7 +25,7 @@ public class GT_Block_Metal extends GT_Block_Storage { for (int i = 0; i < aMats.length; i++) { if (aMats[i].mMetaItemSubID > 0 && aMats[i].mHasParentMod) { - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + i + ".name", "Block of " + aMats[i].mDefaultLocalName); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + i + ".name", "Block of %material"); GT_OreDictUnificator.registerOre(aPrefix, aMats[i], new ItemStack(this, 1, i)); } } diff --git a/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java b/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java index 5595fa86..f46fcc6c 100644 --- a/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java +++ b/src/main/java/gregtech/common/blocks/GT_Block_Ores_Abstract.java @@ -57,8 +57,8 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements if (GregTech_API.sGeneratedMaterials[i] != null) { for (int j = 0; j < aOreMetaCount; j++) { if (!this.getEnabledMetas()[j]) continue; - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + (j * 1000)) + aTextName, getLocalizedName(GregTech_API.sGeneratedMaterials[i])); - GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + ((i + 16000) + (j * 1000)) + aTextName, aTextSmall + getLocalizedName(GregTech_API.sGeneratedMaterials[i])); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + (i + (j * 1000)) + aTextName, getLocalizedNameFormat(GregTech_API.sGeneratedMaterials[i])); + GT_LanguageManager.addStringLocalization(getUnlocalizedName() + "." + ((i + 16000) + (j * 1000)) + aTextName, aTextSmall + getLocalizedNameFormat(GregTech_API.sGeneratedMaterials[i])); if ((GregTech_API.sGeneratedMaterials[i].mTypes & 0x8) != 0 && !aBlockedOres.contains(GregTech_API.sGeneratedMaterials[i])) { GT_OreDictUnificator.registerOre(this.getProcessingPrefix()[j] != null ? this.getProcessingPrefix()[j].get(GregTech_API.sGeneratedMaterials[i]) : "", new ItemStack(this, 1, i + (j * 1000))); if (tHideOres) { @@ -99,33 +99,38 @@ public abstract class GT_Block_Ores_Abstract extends GT_Generic_Block implements FUCKING_LOCK = false; } + public String getLocalizedNameFormat(Materials aMaterial) { + switch (aMaterial.mName) { + case "InfusedAir": + case "InfusedDull": + case "InfusedEarth": + case "InfusedEntropy": + case "InfusedFire": + case "InfusedOrder": + case "InfusedVis": + case "InfusedWater": + return "%material Infused Stone"; + case "Vermiculite": + case "Bentonite": + case "Kaolinite": + case "Talc": + case "BasalticMineralSand": + case "GraniticMineralSand": + case "GlauconiteSand": + case "CassiteriteSand": + case "GarnetSand": + case "QuartzSand": + case "Pitchblende": + case "FullersEarth": + return "%material"; + default: + return "%material" + OrePrefixes.ore.mLocalizedMaterialPost; + } + } + + @Deprecated public String getLocalizedName(Materials aMaterial) { - switch (aMaterial.mName) { - case "InfusedAir": - case "InfusedDull": - case "InfusedEarth": - case "InfusedEntropy": - case "InfusedFire": - case "InfusedOrder": - case "InfusedVis": - case "InfusedWater": - return aMaterial.mDefaultLocalName + " Infused Stone"; - case "Vermiculite": - case "Bentonite": - case "Kaolinite": - case "Talc": - case "BasalticMineralSand": - case "GraniticMineralSand": - case "GlauconiteSand": - case "CassiteriteSand": - case "GarnetSand": - case "QuartzSand": - case "Pitchblende": - case "FullersEarth": - return aMaterial.mDefaultLocalName; - default: - return aMaterial.mDefaultLocalName + OrePrefixes.ore.mLocalizedMaterialPost; - } + return aMaterial.getLocalizedNameForItem(getLocalizedNameFormat(aMaterial)); } public boolean onBlockEventReceived(World p_149696_1_, int p_149696_2_, int p_149696_3_, int p_149696_4_, int p_149696_5_, int p_149696_6_) { diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Machines.java b/src/main/java/gregtech/common/blocks/GT_Item_Machines.java index aa545064..a6a36cf7 100644 --- a/src/main/java/gregtech/common/blocks/GT_Item_Machines.java +++ b/src/main/java/gregtech/common/blocks/GT_Item_Machines.java @@ -2,7 +2,12 @@ package gregtech.common.blocks; import gregtech.api.GregTech_API; import gregtech.api.enums.GT_Values; +import gregtech.api.enums.Materials; import gregtech.api.interfaces.tileentity.IGregTechTileEntity; +import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Cable; +import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Fluid; +import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Frame; +import gregtech.api.metatileentity.implementations.GT_MetaPipeEntity_Item; import gregtech.api.util.GT_ItsNotMyFaultException; import gregtech.api.util.GT_LanguageManager; import gregtech.api.util.GT_Log; @@ -100,6 +105,27 @@ public class GT_Item_Machines return ""; } + public String getItemStackDisplayName(ItemStack aStack) { + String aName = super.getItemStackDisplayName(aStack); + short tDamage = (short) getDamage(aStack); + if (tDamage >= 0 && tDamage < GregTech_API.METATILEENTITIES.length && GregTech_API.METATILEENTITIES[tDamage] != null) { + Materials aMaterial = null; + if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaPipeEntity_Fluid) { + aMaterial = ((GT_MetaPipeEntity_Fluid) GregTech_API.METATILEENTITIES[tDamage]).mMaterial; + } else if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaPipeEntity_Cable) { + aMaterial = ((GT_MetaPipeEntity_Cable) GregTech_API.METATILEENTITIES[tDamage]).mMaterial; + } else if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaPipeEntity_Item) { + aMaterial = ((GT_MetaPipeEntity_Item) GregTech_API.METATILEENTITIES[tDamage]).mMaterial; + } else if (GregTech_API.METATILEENTITIES[tDamage] instanceof GT_MetaPipeEntity_Frame) { + aMaterial = ((GT_MetaPipeEntity_Frame) GregTech_API.METATILEENTITIES[tDamage]).mMaterial; + } + if (aMaterial != null) { + return aMaterial.getLocalizedNameForItem(aName); + } + } + return aName; + } + public void onCreated(ItemStack aStack, World aWorld, EntityPlayer aPlayer) { super.onCreated(aStack, aWorld, aPlayer); short tDamage = (short) getDamage(aStack); diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Ores.java b/src/main/java/gregtech/common/blocks/GT_Item_Ores.java index 399c5d6b..dd54ad1b 100644 --- a/src/main/java/gregtech/common/blocks/GT_Item_Ores.java +++ b/src/main/java/gregtech/common/blocks/GT_Item_Ores.java @@ -1,6 +1,7 @@ package gregtech.common.blocks; import gregtech.api.GregTech_API; +import gregtech.api.enums.Materials; import net.minecraft.block.Block; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemBlock; @@ -24,6 +25,10 @@ public class GT_Item_Ores return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack); } + public String getItemStackDisplayName(ItemStack aStack) { + return Materials.getLocalizedNameForItem(super.getItemStackDisplayName(aStack), getDamage(aStack) % 1000); + } + public boolean placeBlockAt(ItemStack aStack, EntityPlayer aPlayer, World aWorld, int aX, int aY, int aZ, int side, float hitX, float hitY, float hitZ, int aMeta) { short tDamage = (short) getDamage(aStack); if (tDamage > 0) { diff --git a/src/main/java/gregtech/common/blocks/GT_Item_Storage.java b/src/main/java/gregtech/common/blocks/GT_Item_Storage.java index 6dccff42..dad59486 100644 --- a/src/main/java/gregtech/common/blocks/GT_Item_Storage.java +++ b/src/main/java/gregtech/common/blocks/GT_Item_Storage.java @@ -1,6 +1,7 @@ package gregtech.common.blocks; import gregtech.api.GregTech_API; +import gregtech.api.enums.Materials; import net.minecraft.block.Block; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.ItemBlock; @@ -20,6 +21,19 @@ public class GT_Item_Storage extends ItemBlock { return this.field_150939_a.getUnlocalizedName() + "." + getDamage(aStack); } + public String getItemStackDisplayName(ItemStack aStack) { + String aName = super.getItemStackDisplayName(aStack); + if (this.field_150939_a instanceof GT_Block_Metal) { + int aDamage = getDamage(aStack); + if (aDamage >= 0 && aDamage < ((GT_Block_Metal) this.field_150939_a).mMats.length){ + Materials aMaterial = ((GT_Block_Metal) this.field_150939_a).mMats[aDamage]; + if (aMaterial != null) + return aMaterial.getLocalizedNameForItem(aName); + } + } + return aName; + } + public int getMetadata(int aMeta) { return aMeta; } diff --git a/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java b/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java index 2ceeca88..d3dee0ef 100644 --- a/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java +++ b/src/main/java/gregtech/common/items/GT_FluidDisplayItem.java @@ -37,10 +37,10 @@ public class GT_FluidDisplayItem if (aNBT != null) { long tToolTipAmount = aNBT.getLong("mFluidDisplayAmount"); if (tToolTipAmount > 0L) { - aList.add(EnumChatFormatting.BLUE + "Amount: " + tToolTipAmount + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.BLUE + String.format(trans("016", "Amount: %s L"), "" + tToolTipAmount) + EnumChatFormatting.GRAY); } - aList.add(EnumChatFormatting.RED + "Temperature: " + aNBT.getLong("mFluidDisplayHeat") + " K" + EnumChatFormatting.GRAY); - aList.add(EnumChatFormatting.GREEN + "State: " + (aNBT.getBoolean("mFluidState") ? "Gas" : "Liquid") + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.RED + String.format(trans("017", "Temperature: %s K"), "" + aNBT.getLong("mFluidDisplayHeat")) + EnumChatFormatting.GRAY); + aList.add(EnumChatFormatting.GREEN + String.format(trans("018", "State: %s"), aNBT.getBoolean("mFluidState") ? "Gas" : "Liquid") + EnumChatFormatting.GRAY); } } diff --git a/src/main/java/gregtech/common/items/GT_SensorCard_Item.java b/src/main/java/gregtech/common/items/GT_SensorCard_Item.java index b6202be1..7c38ff30 100644 --- a/src/main/java/gregtech/common/items/GT_SensorCard_Item.java +++ b/src/main/java/gregtech/common/items/GT_SensorCard_Item.java @@ -35,9 +35,9 @@ public class GT_SensorCard_Item if (aStack != null) { NBTTagCompound tNBT = aStack.getTagCompound(); if (tNBT == null) { - aList.add("Missing Coodinates!"); + aList.add(trans("014", "Missing Coodinates!")); } else { - aList.add("Device at:"); + aList.add(trans("015", "Device at:")); aList.add(String.format("x: %d, y: %d, z: %d", new Object[]{Integer.valueOf(tNBT.getInteger("x")), Integer.valueOf(tNBT.getInteger("y")), Integer.valueOf(tNBT.getInteger("z"))})); } } diff --git a/src/main/java/gregtech/loaders/preload/GT_Loader_MetaTileEntities.java b/src/main/java/gregtech/loaders/preload/GT_Loader_MetaTileEntities.java index fa1d85ae..d3550644 100644 --- a/src/main/java/gregtech/loaders/preload/GT_Loader_MetaTileEntities.java +++ b/src/main/java/gregtech/loaders/preload/GT_Loader_MetaTileEntities.java @@ -1324,7 +1324,7 @@ public class GT_Loader_MetaTileEntities implements Runnable { long bitsd = GT_ModHandler.RecipeBits.DISMANTLEABLE | GT_ModHandler.RecipeBits.NOT_REMOVABLE | GT_ModHandler.RecipeBits.REVERSIBLE | GT_ModHandler.RecipeBits.BUFFERED; for (int i = 0; i < GregTech_API.sGeneratedMaterials.length; i++) { if (((GregTech_API.sGeneratedMaterials[i] != null) && ((GregTech_API.sGeneratedMaterials[i].mTypes & 0x2) != 0)) || (GregTech_API.sGeneratedMaterials[i] == Materials.Wood)) { - new GT_MetaPipeEntity_Frame(4096 + i, "GT_Frame_" + GregTech_API.sGeneratedMaterials[i], GregTech_API.sGeneratedMaterials[i].mDefaultLocalName + " Frame Box", GregTech_API.sGeneratedMaterials[i]); + new GT_MetaPipeEntity_Frame(4096 + i, "GT_Frame_" + GregTech_API.sGeneratedMaterials[i], "%material Frame Box", GregTech_API.sGeneratedMaterials[i]); } } boolean bEC = !GT_Mod.gregtechproxy.mHardcoreCables; @@ -1384,7 +1384,7 @@ public class GT_Loader_MetaTileEntities implements Runnable { GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Wood), new GT_MetaPipeEntity_Fluid(5102, "GT_Pipe_Wood", "Wooden Fluid Pipe", 0.5F, Materials.Wood, 30, 350, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.Wood), new GT_MetaPipeEntity_Fluid(5103, "GT_Pipe_Wood_Large", "Large Wooden Fluid Pipe", 0.75F, Materials.Wood, 60, 350, aBoolConst_0).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeTiny.get(Materials.Copper), new GT_MetaPipeEntity_Fluid(5110, "GT_Pipe_Copper_Tiny", "Tiny Copper Fluid Pipe", 0.25F, Materials.Copper, 10, 1000, true).getStackForm(1L)); + /*GT_OreDictUnificator.registerOre(OrePrefixes.pipeTiny.get(Materials.Copper), new GT_MetaPipeEntity_Fluid(5110, "GT_Pipe_Copper_Tiny", "Tiny Copper Fluid Pipe", 0.25F, Materials.Copper, 10, 1000, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeSmall.get(Materials.Copper), new GT_MetaPipeEntity_Fluid(5111, "GT_Pipe_Copper_Small", "Small Copper Fluid Pipe", 0.375F, Materials.Copper, 20, 1000, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Copper), new GT_MetaPipeEntity_Fluid(5112, "GT_Pipe_Copper", "Copper Fluid Pipe", 0.5F, Materials.Copper, 60, 1000, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.Copper), new GT_MetaPipeEntity_Fluid(5113, "GT_Pipe_Copper_Large", "Large Copper Fluid Pipe", 0.75F, Materials.Copper, 120, 1000, true).getStackForm(1L)); @@ -1413,16 +1413,23 @@ public class GT_Loader_MetaTileEntities implements Runnable { GT_OreDictUnificator.registerOre(OrePrefixes.pipeSmall.get(Materials.TungstenSteel), new GT_MetaPipeEntity_Fluid(5161, "GT_Pipe_TungstenSteel_Small", "Small Tungstensteel Fluid Pipe", 0.375F, Materials.TungstenSteel, 200, 7500, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.TungstenSteel), new GT_MetaPipeEntity_Fluid(5162, "GT_Pipe_TungstenSteel", "Tungstensteel Fluid Pipe", 0.5F, Materials.TungstenSteel, 600, 7500, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.TungstenSteel), new GT_MetaPipeEntity_Fluid(5163, "GT_Pipe_TungstenSteel_Large", "Large Tungstensteel Fluid Pipe", 0.75F, Materials.TungstenSteel, 1200, 7500, true).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.TungstenSteel), new GT_MetaPipeEntity_Fluid(5164, "GT_Pipe_TungstenSteel_Huge", "Huge Tungstensteel Fluid Pipe", 0.875F, Materials.TungstenSteel, 2400, 7500, true).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.TungstenSteel), new GT_MetaPipeEntity_Fluid(5164, "GT_Pipe_TungstenSteel_Huge", "Huge Tungstensteel Fluid Pipe", 0.875F, Materials.TungstenSteel, 2400, 7500, true).getStackForm(1L));*/ + generateFluidPipes(Materials.Copper, Materials.Copper.mName, 5110, 60, 1000, true); + generateFluidPipes(Materials.Bronze, Materials.Bronze.mName, 5120, 120, 2000, true); + generateFluidPipes(Materials.Steel, Materials.Steel.mName, 5130, 240, 2500, true); + generateFluidPipes(Materials.StainlessSteel, Materials.StainlessSteel.mName, 5140, 360, 3000, true); + generateFluidPipes(Materials.Titanium, Materials.Titanium.mName, 5150, 480, 5000, true); + generateFluidPipes(Materials.TungstenSteel, Materials.TungstenSteel.mName, 5160, 600, 7500, true); GT_OreDictUnificator.registerOre(OrePrefixes.pipeSmall.get(Materials.Ultimate), new GT_MetaPipeEntity_Fluid(5165, "GT_Pipe_HighPressure_Small", "Small High Pressure Fluid Pipe", 0.375F, Materials.Redstone, 4800, 1500, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Ultimate), new GT_MetaPipeEntity_Fluid(5166, "GT_Pipe_HighPressure", "High Pressure Fluid Pipe", 0.5F, Materials.Redstone, 7200, 1500, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.Ultimate), new GT_MetaPipeEntity_Fluid(5167, "GT_Pipe_HighPressure_Large", "Large High Pressure Fluid Pipe", 0.75F, Materials.Redstone, 9600, 1500, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Superconductor), new GT_MetaPipeEntity_Fluid(5168, "GT_Pipe_PlasmaContain", "Plasma Containment Pipe", 0.5F, Materials.Glowstone, 240, 100000, true).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeTiny.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5170, "GT_Pipe_Plastic_Tiny", "Tiny Plastic Fluid Pipe", 0.25F, Materials.Plastic, 60, 350, true).getStackForm(1L)); + /*GT_OreDictUnificator.registerOre(OrePrefixes.pipeTiny.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5170, "GT_Pipe_Plastic_Tiny", "Tiny Plastic Fluid Pipe", 0.25F, Materials.Plastic, 60, 350, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeSmall.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5171, "GT_Pipe_Plastic_Small", "Small Plastic Fluid Pipe", 0.375F, Materials.Plastic, 120, 350, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5172, "GT_Pipe_Plastic", "Plastic Fluid Pipe", 0.5F, Materials.Plastic, 360, 350, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5173, "GT_Pipe_Plastic_Large", "Large Plastic Fluid Pipe", 0.75F, Materials.Plastic, 720, 350, true).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5174, "GT_Pipe_Plastic_Huge", "Huge Plastic Fluid Pipe", 0.875F, Materials.Plastic, 1440, 350, true).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.Plastic), new GT_MetaPipeEntity_Fluid(5174, "GT_Pipe_Plastic_Huge", "Huge Plastic Fluid Pipe", 0.875F, Materials.Plastic, 1440, 350, true).getStackForm(1L));*/ + generateFluidPipes(Materials.Plastic, Materials.Plastic.mName, "Plastic", 5170, 360, 350, true); generateFluidPipes(Materials.Polytetrafluoroethylene, Materials.Polytetrafluoroethylene.mName, "PTFE", 5175, 480, 600, true); GT_Values.RA.addAssemblerRecipe(GT_OreDictUnificator.get(OrePrefixes.pipeSmall, Materials.TungstenSteel, 1L), ItemList.Electric_Pump_EV.get(1L, new Object[0]), GT_OreDictUnificator.get(OrePrefixes.pipeSmall, Materials.Ultimate, 1L), 300, 96); @@ -1432,7 +1439,7 @@ public class GT_Loader_MetaTileEntities implements Runnable { GT_ModHandler.addCraftingRecipe(GT_OreDictUnificator.get(OrePrefixes.pipeMedium, Materials.Superconductor, 1L), bitsd, new Object[]{"WSW", aTextCableHull, "WSW", 'M', OrePrefixes.pipeSmall.get(Materials.Titanium), 'C', OrePrefixes.plate.get(Materials.NeodymiumMagnetic), 'W', OrePrefixes.plate.get(Materials.Plastic), 'S', OrePrefixes.wireGt02.get(Materials.Superconductor)}); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Brass), new GT_MetaPipeEntity_Item(5602, "GT_Pipe_Brass", "Brass Item Pipe", 0.5F, Materials.Brass, 1, 32768, aBoolConst_0).getStackForm(1L)); + /*GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(Materials.Brass), new GT_MetaPipeEntity_Item(5602, "GT_Pipe_Brass", "Brass Item Pipe", 0.5F, Materials.Brass, 1, 32768, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(Materials.Brass), new GT_MetaPipeEntity_Item(5603, "GT_Pipe_Brass_Large", "Large Brass Item Pipe", 0.75F, Materials.Brass, 2, 16384, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.Brass), new GT_MetaPipeEntity_Item(5604, "GT_Pipe_Brass_Huge", "Huge Brass Item Pipe", 0.875F, Materials.Brass, 4, 8192, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeRestrictiveMedium.get(Materials.Brass), new GT_MetaPipeEntity_Item(5607, "GT_Pipe_Restrictive_Brass", "Restrictive Brass Item Pipe", 0.5F, Materials.Brass, 1, 3276800, true).getStackForm(1L)); @@ -1455,12 +1462,16 @@ public class GT_Loader_MetaTileEntities implements Runnable { GT_OreDictUnificator.registerOre(OrePrefixes.pipeHuge.get(Materials.Osmium), new GT_MetaPipeEntity_Item(5634, "GT_Pipe_Osmium_Huge", "Huge Osmium Item Pipe", 0.875F, Materials.Osmium, 32, 1024, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeRestrictiveMedium.get(Materials.Osmium), new GT_MetaPipeEntity_Item(5637, "GT_Pipe_Restrictive_Osmium", "Restrictive Osmium Item Pipe", 0.5F, Materials.Osmium, 8, 409600, true).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeRestrictiveLarge.get(Materials.Osmium), new GT_MetaPipeEntity_Item(5638, "GT_Pipe_Restrictive_Osmium_Large", "Large Restrictive Osmium Item Pipe", 0.75F, Materials.Osmium, 16, 204800, true).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.pipeRestrictiveHuge.get(Materials.Osmium), new GT_MetaPipeEntity_Item(5639, "GT_Pipe_Restrictive_Osmium_Huge", "Huge Restrictive Osmium Item Pipe", 0.875F, Materials.Osmium, 32, 102400, true).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.pipeRestrictiveHuge.get(Materials.Osmium), new GT_MetaPipeEntity_Item(5639, "GT_Pipe_Restrictive_Osmium_Huge", "Huge Restrictive Osmium Item Pipe", 0.875F, Materials.Osmium, 32, 102400, true).getStackForm(1L));*/ + generateItemPipes(Materials.Brass, Materials.Brass.mName, 5602, 1); + generateItemPipes(Materials.Electrum, Materials.Electrum.mName, 5612, 2); + generateItemPipes(Materials.Platinum, Materials.Platinum.mName, 5622, 4); + generateItemPipes(Materials.Osmium, Materials.Osmium.mName, 5632, 8); generateItemPipes(Materials.PolyvinylChloride, Materials.PolyvinylChloride.mName, "PVC", 5640, 4); - generateItemPipes(Materials.WroughtIron, Materials.WroughtIron.mName, "Wrought Iron", 5646, 1); - generateItemPipes(Materials.Nickel, Materials.Nickel.mName, "Nickel", 5652, 1); - generateItemPipes(Materials.Cobalt, Materials.Cobalt.mName, "Cobalt", 5658, 2); - generateItemPipes(Materials.Aluminium, Materials.Aluminium.mName, "Aluminium", 5664, 2); + generateItemPipes(Materials.WroughtIron, Materials.WroughtIron.mName, 5646, 1); + generateItemPipes(Materials.Nickel, Materials.Nickel.mName, 5652, 1); + generateItemPipes(Materials.Cobalt, Materials.Cobalt.mName, 5658, 2); + generateItemPipes(Materials.Aluminium, Materials.Aluminium.mName, 5664, 2); ItemList.Automation_ChestBuffer_ULV.set(new GT_MetaTileEntity_ChestBuffer(9230, "automation.chestbuffer.tier.00", "Ultra Low Voltage Chest Buffer", 0).getStackForm(1L)); @@ -1608,19 +1619,19 @@ public class GT_Loader_MetaTileEntities implements Runnable { } private static void makeWires(Materials aMaterial, int aStartID, long aLossInsulated, long aLoss, long aAmperage, long aVoltage, boolean aInsulatable, boolean aAutoInsulated) { - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt01, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 0, aTextWire1 + aMaterial.mName.toLowerCase() + ".01", "1x " + aMaterial.mDefaultLocalName + aTextWire2, 0.125F, aMaterial, aLoss, 1L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt02, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 1, aTextWire1 + aMaterial.mName.toLowerCase() + ".02", "2x " + aMaterial.mDefaultLocalName + aTextWire2, 0.25F, aMaterial, aLoss, 2L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt04, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 2, aTextWire1 + aMaterial.mName.toLowerCase() + ".04", "4x " + aMaterial.mDefaultLocalName + aTextWire2, 0.375F, aMaterial, aLoss, 4L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt08, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 3, aTextWire1 + aMaterial.mName.toLowerCase() + ".08", "8x " + aMaterial.mDefaultLocalName + aTextWire2, 0.5F, aMaterial, aLoss, 8L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt12, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 4, aTextWire1 + aMaterial.mName.toLowerCase() + ".12", "12x " + aMaterial.mDefaultLocalName + aTextWire2, 0.625F, aMaterial, aLoss, 12L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.wireGt16, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 5, aTextWire1 + aMaterial.mName.toLowerCase() + ".16", "16x " + aMaterial.mDefaultLocalName + aTextWire2, 0.75F, aMaterial, aLoss, 16L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt01, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 0, aTextWire1 + aMaterial.mName.toLowerCase() + ".01", "1x %material" + aTextWire2, 0.125F, aMaterial, aLoss, 1L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt02, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 1, aTextWire1 + aMaterial.mName.toLowerCase() + ".02", "2x %material" + aTextWire2, 0.25F, aMaterial, aLoss, 2L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt04, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 2, aTextWire1 + aMaterial.mName.toLowerCase() + ".04", "4x %material" + aTextWire2, 0.375F, aMaterial, aLoss, 4L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt08, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 3, aTextWire1 + aMaterial.mName.toLowerCase() + ".08", "8x %material" + aTextWire2, 0.5F, aMaterial, aLoss, 8L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt12, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 4, aTextWire1 + aMaterial.mName.toLowerCase() + ".12", "12x %material" + aTextWire2, 0.625F, aMaterial, aLoss, 12L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.wireGt16, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 5, aTextWire1 + aMaterial.mName.toLowerCase() + ".16", "16x %material" + aTextWire2, 0.75F, aMaterial, aLoss, 16L * aAmperage, aVoltage, aBoolConst_0, !aAutoInsulated).getStackForm(1L)); if (aInsulatable) { - GT_OreDictUnificator.registerOre(OrePrefixes.cableGt01, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 6, aTextCable1 + aMaterial.mName.toLowerCase() + ".01", "1x " + aMaterial.mDefaultLocalName + aTextCable2, 0.25F, aMaterial, aLossInsulated, 1L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.cableGt02, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 7, aTextCable1 + aMaterial.mName.toLowerCase() + ".02", "2x " + aMaterial.mDefaultLocalName + aTextCable2, 0.375F, aMaterial, aLossInsulated, 2L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.cableGt04, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 8, aTextCable1 + aMaterial.mName.toLowerCase() + ".04", "4x " + aMaterial.mDefaultLocalName + aTextCable2, 0.5F, aMaterial, aLossInsulated, 4L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.cableGt08, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 9, aTextCable1 + aMaterial.mName.toLowerCase() + ".08", "8x " + aMaterial.mDefaultLocalName + aTextCable2, 0.625F, aMaterial, aLossInsulated, 8L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); - GT_OreDictUnificator.registerOre(OrePrefixes.cableGt12, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 10, aTextCable1 + aMaterial.mName.toLowerCase() + ".12", "12x " + aMaterial.mDefaultLocalName + aTextCable2, 0.75F, aMaterial, aLossInsulated, 12L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); - //GT_OreDictUnificator.registerOre(OrePrefixes.cableGt16, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 11, aTextCable1 + aMaterial.mName.toLowerCase() + ".16", "16x " + aMaterial.mDefaultLocalName + aTextCable2, 0.875F, aMaterial, aLossInsulated, 16L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.cableGt01, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 6, aTextCable1 + aMaterial.mName.toLowerCase() + ".01", "1x %material" + aTextCable2, 0.25F, aMaterial, aLossInsulated, 1L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.cableGt02, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 7, aTextCable1 + aMaterial.mName.toLowerCase() + ".02", "2x %material" + aTextCable2, 0.375F, aMaterial, aLossInsulated, 2L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.cableGt04, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 8, aTextCable1 + aMaterial.mName.toLowerCase() + ".04", "4x %material" + aTextCable2, 0.5F, aMaterial, aLossInsulated, 4L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.cableGt08, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 9, aTextCable1 + aMaterial.mName.toLowerCase() + ".08", "8x %material" + aTextCable2, 0.625F, aMaterial, aLossInsulated, 8L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + GT_OreDictUnificator.registerOre(OrePrefixes.cableGt12, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 10, aTextCable1 + aMaterial.mName.toLowerCase() + ".12", "12x %material" + aTextCable2, 0.75F, aMaterial, aLossInsulated, 12L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); + //GT_OreDictUnificator.registerOre(OrePrefixes.cableGt16, aMaterial, new GT_MetaPipeEntity_Cable(aStartID + 11, aTextCable1 + aMaterial.mName.toLowerCase() + ".16", "16x %material" + aTextCable2, 0.875F, aMaterial, aLossInsulated, 16L * aAmperage, aVoltage, true, aBoolConst_0).getStackForm(1L)); } } @@ -1632,6 +1643,10 @@ public class GT_Loader_MetaTileEntities implements Runnable { run4(); } + private static void generateItemPipes(Materials aMaterial, String name, int startID, int baseInvSlots){ + generateItemPipes(aMaterial, name, "%material", startID, baseInvSlots); + } + private static void generateItemPipes(Materials aMaterial, String name, String displayName, int startID, int baseInvSlots){ GT_OreDictUnificator.registerOre(OrePrefixes.pipeMedium.get(aMaterial), new GT_MetaPipeEntity_Item(startID, "GT_Pipe_" + displayName, displayName + " Item Pipe", 0.50F, aMaterial, baseInvSlots, 32768 / baseInvSlots, aBoolConst_0).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeLarge.get(aMaterial), new GT_MetaPipeEntity_Item(startID + 1, "GT_Pipe_" + displayName + "_Large", "Large " + displayName + " Item Pipe", 0.75F, aMaterial, baseInvSlots * 2, 16384 / baseInvSlots, aBoolConst_0).getStackForm(1L)); @@ -1642,6 +1657,10 @@ public class GT_Loader_MetaTileEntities implements Runnable { } + private static void generateFluidPipes(Materials aMaterial, String name, int startID, int baseCapacity, int heatCapacity, boolean gasProof){ + generateFluidPipes(aMaterial, name, "%material", startID, baseCapacity, heatCapacity, gasProof); + } + private static void generateFluidPipes(Materials aMaterial, String name, String displayName, int startID, int baseCapacity, int heatCapacity, boolean gasProof){ GT_OreDictUnificator.registerOre(OrePrefixes.pipeTiny.get(aMaterial), new GT_MetaPipeEntity_Fluid(startID, "GT_Pipe_" + name + "_Tiny", "Tiny " + displayName + " Fluid Pipe", 0.25F, aMaterial, baseCapacity / 6, heatCapacity, gasProof).getStackForm(1L)); GT_OreDictUnificator.registerOre(OrePrefixes.pipeSmall.get(aMaterial), new GT_MetaPipeEntity_Fluid(startID + 1, "GT_Pipe_" + name + "_Small", "Small " + displayName + " Fluid Pipe", 0.375F, aMaterial, baseCapacity / 3, heatCapacity, gasProof).getStackForm(1L));