diff options
author | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2019-05-13 15:45:29 +1000 |
---|---|---|
committer | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2019-05-13 15:45:29 +1000 |
commit | f7390af19986b4e4370379bb46dee71f12b717e8 (patch) | |
tree | c250545984b437c99d1951975fbcbd12da205985 /src/Java/gtPlusPlus/core | |
parent | f82bd998288253230713cb146f6294be2d02260c (diff) | |
download | GT5-Unofficial-f7390af19986b4e4370379bb46dee71f12b717e8.tar.gz GT5-Unofficial-f7390af19986b4e4370379bb46dee71f12b717e8.tar.bz2 GT5-Unofficial-f7390af19986b4e4370379bb46dee71f12b717e8.zip |
+ Added High Quality Industrial Diamond.
+ Added various material components.
+ Added a debug machine used for calling the Garbage Collector.
+ Added recipe to obtain Hot Water.
+ Added way to obtain Dragonsblood.
+ Added lots of quick access fluids directly to FluidUtils.
% Updated English Locale.
$ Fixed issue preventing all Multiblocks from forming.
$ Fixed some minor texture issues.
Diffstat (limited to 'src/Java/gtPlusPlus/core')
16 files changed, 310 insertions, 9 deletions
diff --git a/src/Java/gtPlusPlus/core/common/CommonProxy.java b/src/Java/gtPlusPlus/core/common/CommonProxy.java index cacc471249..23bdb2c5f1 100644 --- a/src/Java/gtPlusPlus/core/common/CommonProxy.java +++ b/src/Java/gtPlusPlus/core/common/CommonProxy.java @@ -27,6 +27,7 @@ import gtPlusPlus.core.handler.COMPAT_IntermodStaging; import gtPlusPlus.core.handler.GuiHandler; import gtPlusPlus.core.handler.StopAnnoyingFuckingAchievements; import gtPlusPlus.core.handler.events.BlockEventHandler; +import gtPlusPlus.core.handler.events.EnderDragonDeathHandler; import gtPlusPlus.core.handler.events.GeneralTooltipEventHandler; import gtPlusPlus.core.handler.events.PickaxeBlockBreakEventHandler; import gtPlusPlus.core.handler.events.ZombieBackupSpawnEventHandler; @@ -145,6 +146,7 @@ public class CommonProxy { // Register Chunkloader ForgeChunkManager.setForcedChunkLoadingCallback(GTplusplus.instance, ChunkManager.getInstance()); Utils.registerEvent(ChunkManager.getInstance()); + Utils.registerEvent(new EnderDragonDeathHandler()); if (ConfigSwitches.disableZombieReinforcement) { // Make Zombie reinforcements fuck off. diff --git a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java index 1e3cb0ffbb..a00d1ea152 100644 --- a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java +++ b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java @@ -22,6 +22,9 @@ import gtPlusPlus.core.recipe.*; import gtPlusPlus.core.util.minecraft.ItemUtils; import gtPlusPlus.core.util.minecraft.RecipeUtils; import gtPlusPlus.xmod.gregtech.HANDLER_GT; +import gtPlusPlus.xmod.gregtech.api.enums.GregtechItemList; +import gtPlusPlus.xmod.gregtech.common.tileentities.machines.basic.GregtechMetaGarbageCollector; +import gtPlusPlus.xmod.gregtech.common.tileentities.machines.basic.GregtechMetaPollutionCreator; import gtPlusPlus.xmod.gregtech.loaders.RecipeGen_Recycling; import gtPlusPlus.xmod.gregtech.registration.gregtech.*; import net.minecraft.item.ItemStack; @@ -49,6 +52,14 @@ public class COMPAT_HANDLER { public static void registerGregtechMachines() { if (Gregtech) { + //Debug + GregtechItemList.Garbage_Collector_Debug_Machine.set( + new GregtechMetaGarbageCollector( + "garbagecollector.01.tier.single", + "JVM Garbage Collector", + "Useful for debugging or smoother performance on local servers").getStackForm(1L)); + + //Free IDs /* --- diff --git a/src/Java/gtPlusPlus/core/handler/events/EnderDragonDeathHandler.java b/src/Java/gtPlusPlus/core/handler/events/EnderDragonDeathHandler.java new file mode 100644 index 0000000000..c1c2341dd6 --- /dev/null +++ b/src/Java/gtPlusPlus/core/handler/events/EnderDragonDeathHandler.java @@ -0,0 +1,57 @@ +package gtPlusPlus.core.handler.events; + +import cpw.mods.fml.common.eventhandler.SubscribeEvent; +import gtPlusPlus.core.material.ELEMENT; +import gtPlusPlus.core.util.Utils; +import gtPlusPlus.core.util.math.MathUtils; +import gtPlusPlus.core.util.minecraft.PlayerUtils; +import gtPlusPlus.core.util.reflect.ReflectionUtils; +import net.minecraft.entity.boss.EntityDragon; +import net.minecraftforge.event.entity.living.LivingDropsEvent; + +public class EnderDragonDeathHandler { + + private static final String mDragonClassName = "chylex.hee.entity.boss.EntityBossDragon"; + private static final boolean mHEE; + private static final Class mHardcoreDragonClass; + + static { + mHEE = ReflectionUtils.doesClassExist(mDragonClassName); + mHardcoreDragonClass = (mHEE ? ReflectionUtils.getClass(mDragonClassName) : null); + } + + @SubscribeEvent + public void onEntityDrop(LivingDropsEvent event) { + + boolean aDidDrop = false; + + //HEE Dragon + if (mHEE) { + if (mHardcoreDragonClass != null) { + if (mHardcoreDragonClass.isInstance(event.entityLiving)) { + for (int y = 0; y < MathUtils.randInt(100, 250); y++) { + int aAmount = MathUtils.randInt(5, 25); + event.entityLiving.entityDropItem(ELEMENT.STANDALONE.DRAGON_METAL.getNugget(aAmount), MathUtils.randFloat(0, 1)); + aDidDrop = true; + } + } + } + } + //Vanilla Dragon or any other dragon that extends it + else { + if (event.entityLiving instanceof EntityDragon) { + for (int y = 0; y < MathUtils.randInt(25, 50); y++) { + int aAmount = MathUtils.randInt(1, 10); + event.entityLiving.entityDropItem(ELEMENT.STANDALONE.DRAGON_METAL.getNugget(aAmount), MathUtils.randFloat(0, 1)); + aDidDrop = true; + } + } + } + + if (aDidDrop) { + PlayerUtils.messageAllPlayers("Small quantities of Dragonsblood has crystalized after the death of the Ender Dragon!"); + } + + } + +} diff --git a/src/Java/gtPlusPlus/core/item/ModItems.java b/src/Java/gtPlusPlus/core/item/ModItems.java index 9b32c55d2d..db218cf251 100644 --- a/src/Java/gtPlusPlus/core/item/ModItems.java +++ b/src/Java/gtPlusPlus/core/item/ModItems.java @@ -94,6 +94,7 @@ import gtPlusPlus.core.util.data.StringUtils; import gtPlusPlus.core.util.debug.DEBUG_INIT; import gtPlusPlus.core.util.minecraft.FluidUtils; import gtPlusPlus.core.util.minecraft.ItemUtils; +import gtPlusPlus.core.util.minecraft.MaterialUtils; import gtPlusPlus.core.util.reflect.ReflectionUtils; import gtPlusPlus.everglades.GTplusplus_Everglades; import gtPlusPlus.xmod.eio.material.MaterialEIO; @@ -361,6 +362,8 @@ public final class ModItems { public static MonsterKillerBaseBauble itemAmuletMonsterKiller_Nether; public static MonsterKillerBaseBauble itemAmuletMonsterKiller_Infernal; + public static CoreItem itemExquisiteIndustrialDiamond; + static { Logger.INFO("Items!"); //Default item used when recipes fail, handy for debugging. Let's make sure they exist when this class is called upon. @@ -851,6 +854,63 @@ public final class ModItems { itemHotTitaniumIngot = ItemUtils.getItemStackOfAmountFromOreDictNoBroken("ingotHotTitanium", 1); } + //Industrial Diamonds + itemExquisiteIndustrialDiamond = new CoreItem("IndustrialDiamondExquisite", "High Quality Industrial Diamond", tabMisc); + ItemStack tempStack = itemExquisiteIndustrialDiamond.getStack(); + ItemUtils.addItemToOreDictionary(tempStack, "gemDiamond"); + ItemUtils.addItemToOreDictionary(tempStack, "craftingIndustrialDiamond"); + ItemUtils.addItemToOreDictionary(tempStack, "gemExquisiteDiamond"); + ItemUtils.addItemToOreDictionary(tempStack, "craftingExquisiteIndustrialDiamond"); + + //Custom GT++ Crafting Components + + //Springs + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SPRING, ELEMENT.STANDALONE.CELESTIAL_TUNGSTEN); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SPRING, ELEMENT.STANDALONE.WHITE_METAL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SPRING, ALLOY.NITINOL_60); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SPRING, ALLOY.AQUATIC_STEEL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SPRING, ALLOY.EGLIN_STEEL); + + //Small Springs + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SMALLSPRING, ALLOY.MARAGING250); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SMALLSPRING, ALLOY.NICHROME); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SMALLSPRING, ALLOY.STABALLOY); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SMALLSPRING, ALLOY.STEEL_BLACK); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.SMALLSPRING, ALLOY.BLACK_TITANIUM); + + //Fine Wire + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ELEMENT.STANDALONE.WHITE_METAL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ELEMENT.getInstance().PALLADIUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ELEMENT.getInstance().ZIRCONIUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ALLOY.LEAGRISIUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ALLOY.BABBIT_ALLOY); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ALLOY.KOBOLDITE); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ALLOY.HG1223); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.FINEWIRE, ALLOY.QUANTUM); + + //Dense Plates + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.POTIN); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.AQUATIC_STEEL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.BRONZE); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.OSMIRIDIUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.QUANTUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.STEEL_BLACK); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.STAINLESS_STEEL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.EGLIN_STEEL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.MARAGING300); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ALLOY.TALONITE); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.HYPOGEN); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.RHUGNOR); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.ADVANCED_NITINOL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.ASTRAL_TITANIUM); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.CELESTIAL_TUNGSTEN); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.WHITE_METAL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.BLACK_METAL); + MaterialUtils.generateComponentAndAssignToAMaterial(ComponentTypes.PLATEHEAVY, ELEMENT.STANDALONE.GRANITE); + + + + //Special Sillyness if (true) { diff --git a/src/Java/gtPlusPlus/core/item/base/BaseItemComponent.java b/src/Java/gtPlusPlus/core/item/base/BaseItemComponent.java index 33198e8d41..90e831cbb4 100644 --- a/src/Java/gtPlusPlus/core/item/base/BaseItemComponent.java +++ b/src/Java/gtPlusPlus/core/item/base/BaseItemComponent.java @@ -248,12 +248,17 @@ public class BaseItemComponent extends Item{ public int getColorFromItemStack(final ItemStack stack, final int renderPass) { + if (this.componentType == ComponentTypes.CELL || this.componentType == ComponentTypes.PLASMACELL) { if (renderPass == 0 && !CORE.ConfigSwitches.useGregtechTextures){ return Utils.rgbtoHexValue(255, 255, 255); } if (renderPass == 1 && CORE.ConfigSwitches.useGregtechTextures){ return Utils.rgbtoHexValue(255, 255, 255); } + } + if (this.componentType == ComponentTypes.PLATEHEAVY) { + + } @@ -495,7 +500,10 @@ public class BaseItemComponent extends Item{ PLASMACELL("CellPlasma", " Plasma Cell", "cellPlasma", OrePrefixes.cellPlasma), CELL("Cell", " Cell", "cell", OrePrefixes.cell), NUGGET("Nugget", " Nugget", "nugget", OrePrefixes.nugget), - PLATEHEAVY("HeavyPlate", " Heavy Plate", "plateHeavy", OrePrefixes.plateDense); + PLATEHEAVY("HeavyPlate", "Heavy@Plate", "plateHeavy", OrePrefixes.plateDense), + SPRING("Spring", " Spring", "spring", OrePrefixes.spring), + SMALLSPRING("SmallSpring", "Small@Spring", "springSmall", OrePrefixes.springSmall), + FINEWIRE("FineWire", "Fine@Wire", "wireFine", OrePrefixes.wireFine),; private String COMPONENT_NAME; private String DISPLAY_NAME; diff --git a/src/Java/gtPlusPlus/core/item/base/CoreItem.java b/src/Java/gtPlusPlus/core/item/base/CoreItem.java index 376be7bac8..7ce96b2a88 100644 --- a/src/Java/gtPlusPlus/core/item/base/CoreItem.java +++ b/src/Java/gtPlusPlus/core/item/base/CoreItem.java @@ -17,6 +17,7 @@ import net.minecraft.world.World; import gtPlusPlus.api.objects.Logger; import gtPlusPlus.core.lib.CORE; +import gtPlusPlus.core.util.minecraft.ItemUtils; public class CoreItem extends Item { @@ -221,6 +222,10 @@ public class CoreItem extends Item public boolean isRepairable() { return false; } + + public ItemStack getStack() { + return ItemUtils.getSimpleStack(this); + } /* @Override public String getItemStackDisplayName(final ItemStack tItem) { diff --git a/src/Java/gtPlusPlus/core/item/base/plates/BaseItemPlateHeavy.java b/src/Java/gtPlusPlus/core/item/base/plates/BaseItemPlateHeavy.java new file mode 100644 index 0000000000..c9072b0d82 --- /dev/null +++ b/src/Java/gtPlusPlus/core/item/base/plates/BaseItemPlateHeavy.java @@ -0,0 +1,47 @@ +package gtPlusPlus.core.item.base.plates; + +import cpw.mods.fml.relauncher.Side; +import cpw.mods.fml.relauncher.SideOnly; +import gtPlusPlus.core.item.base.BaseItemComponent; +import gtPlusPlus.core.lib.CORE; +import gtPlusPlus.core.material.Material; +import net.minecraft.client.renderer.texture.IIconRegister; +import net.minecraft.util.IIcon; + +public class BaseItemPlateHeavy extends BaseItemComponent{ + + final static ComponentTypes HEAVY = ComponentTypes.PLATEHEAVY; + + public BaseItemPlateHeavy(final Material material) { + super(material, HEAVY); + } + + @Override + public String getCorrectTextures(){ + return CORE.MODID + ":" + "itemHeavyPlate"; + } + + @Override + @SideOnly(Side.CLIENT) + public boolean requiresMultipleRenderPasses(){ + return true; + } + + @Override + public void registerIcons(final IIconRegister i) { + this.base = i.registerIcon(CORE.MODID + ":" + "itemHeavyPlate"); + this.overlay = i.registerIcon(CORE.MODID + ":" + "itemHeavyPlate_Overlay"); + } + + @Override + public IIcon getIconFromDamageForRenderPass(final int damage, final int pass) { + + if (pass == 0) { + return this.base; + } + else { + return this.overlay; + } + + } +} diff --git a/src/Java/gtPlusPlus/core/item/bauble/ElectricBaseBauble.java b/src/Java/gtPlusPlus/core/item/bauble/ElectricBaseBauble.java index 8472549e8d..cfa5cb363d 100644 --- a/src/Java/gtPlusPlus/core/item/bauble/ElectricBaseBauble.java +++ b/src/Java/gtPlusPlus/core/item/bauble/ElectricBaseBauble.java @@ -9,11 +9,9 @@ import cpw.mods.fml.common.registry.GameRegistry; import cpw.mods.fml.relauncher.Side; import cpw.mods.fml.relauncher.SideOnly; import gregtech.api.enums.GT_Values; -import gtPlusPlus.api.objects.Logger; import gtPlusPlus.core.creative.AddToCreativeTab; import gtPlusPlus.core.lib.CORE; import gtPlusPlus.core.util.math.MathUtils; -import gtPlusPlus.xmod.gregtech.common.helpers.ChargingHelper; import ic2.api.item.ElectricItem; import ic2.api.item.IElectricItem; import ic2.api.item.IElectricItemManager; @@ -21,7 +19,6 @@ import net.minecraft.creativetab.CreativeTabs; import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.util.EnumChatFormatting; @@ -54,6 +51,7 @@ public abstract class ElectricBaseBauble extends BaseBauble implements IElectric public abstract String getTextureNameForBauble(); + @SuppressWarnings("unchecked") @SideOnly(Side.CLIENT) @Override public void getSubItems(Item item, CreativeTabs par2CreativeTabs, List itemList) { diff --git a/src/Java/gtPlusPlus/core/item/bauble/MonsterKillerBaseBauble.java b/src/Java/gtPlusPlus/core/item/bauble/MonsterKillerBaseBauble.java index aa89ff1627..aab302688b 100644 --- a/src/Java/gtPlusPlus/core/item/bauble/MonsterKillerBaseBauble.java +++ b/src/Java/gtPlusPlus/core/item/bauble/MonsterKillerBaseBauble.java @@ -169,7 +169,7 @@ public class MonsterKillerBaseBauble extends ElectricBaseBauble { @Override public String getTextureNameForBauble() { - return CORE.MODID + ":" + "baubles/itemAmulet"; + return "baubles/itemAmulet"; } } diff --git a/src/Java/gtPlusPlus/core/lib/CORE.java b/src/Java/gtPlusPlus/core/lib/CORE.java index 632378987a..6b6d83d0bd 100644 --- a/src/Java/gtPlusPlus/core/lib/CORE.java +++ b/src/Java/gtPlusPlus/core/lib/CORE.java @@ -282,4 +282,12 @@ public class CORE { public static final String VERSION = "0.1"; } + public static final void crash() { + System.exit(0); + } + + public static final void gc() { + System.gc(); + } + }
\ No newline at end of file diff --git a/src/Java/gtPlusPlus/core/material/ALLOY.java b/src/Java/gtPlusPlus/core/material/ALLOY.java index 1df843da0b..95e3631aaf 100644 --- a/src/Java/gtPlusPlus/core/material/ALLOY.java +++ b/src/Java/gtPlusPlus/core/material/ALLOY.java @@ -15,7 +15,7 @@ public final class ALLOY { public static final Material KANTHAL = MaterialUtils.generateMaterialFromGtENUM(Materials.Kanthal); public static final Material NICHROME = MaterialUtils.generateMaterialFromGtENUM(Materials.Nichrome); public static final Material TUNGSTENSTEEL = MaterialUtils.generateMaterialFromGtENUM(Materials.TungstenSteel); - public static final Material STAINLESSSTEEL = MaterialUtils.generateMaterialFromGtENUM(Materials.StainlessSteel); + public static final Material STAINLESS_STEEL = MaterialUtils.generateMaterialFromGtENUM(Materials.StainlessSteel); public static final Material OSMIRIDIUM = MaterialUtils.generateMaterialFromGtENUM(Materials.Osmiridium); public static final Material ENERGYCRYSTAL = new Material( @@ -804,7 +804,7 @@ public final class ALLOY { true, //Uses Blast furnace? //Material Stacks with Percentage of required elements. new MaterialStack[]{ - new MaterialStack(ALLOY.STAINLESSSTEEL, 10), + new MaterialStack(ALLOY.STAINLESS_STEEL, 10), new MaterialStack(ALLOY.TUNGSTEN_CARBIDE, 10), new MaterialStack(ALLOY.NICHROME, 10), new MaterialStack(ALLOY.BRONZE, 10), diff --git a/src/Java/gtPlusPlus/core/recipe/RECIPES_GREGTECH.java b/src/Java/gtPlusPlus/core/recipe/RECIPES_GREGTECH.java index e264a680fc..bd19eca5e9 100644 --- a/src/Java/gtPlusPlus/core/recipe/RECIPES_GREGTECH.java +++ b/src/Java/gtPlusPlus/core/recipe/RECIPES_GREGTECH.java @@ -91,10 +91,16 @@ public class RECIPES_GREGTECH { assemblyLineRecipes(); latheRecipes(); vacuumFreezerRecipes(); + fluidheaterRecipes(); addFuels(); } + private static void fluidheaterRecipes() { + GT_Values.RA.addFluidHeaterRecipe(CI.getNumberedCircuit(20), FluidUtils.getWater(1000), FluidUtils.getHotWater(1000), 30, 30); + + } + private static void vacuumFreezerRecipes() { GT_Values.RA.addVacuumFreezerRecipe(GregtechItemList.Bomb_Cast_Molten.get(1), GregtechItemList.Bomb_Cast_Set.get(1), 20 * 30); } diff --git a/src/Java/gtPlusPlus/core/recipe/common/CI.java b/src/Java/gtPlusPlus/core/recipe/common/CI.java index dffb438e4a..80abc18158 100644 --- a/src/Java/gtPlusPlus/core/recipe/common/CI.java +++ b/src/Java/gtPlusPlus/core/recipe/common/CI.java @@ -574,7 +574,7 @@ public class CI { private static final Material[] aMaterial_Tertiary = new Material[] { ALLOY.STEEL, ELEMENT.getInstance().ALUMINIUM, - ALLOY.STAINLESSSTEEL, + ALLOY.STAINLESS_STEEL, ELEMENT.getInstance().TUNGSTEN, ALLOY.HASTELLOY_N, ALLOY.ENERGYCRYSTAL, diff --git a/src/Java/gtPlusPlus/core/util/minecraft/FluidUtils.java b/src/Java/gtPlusPlus/core/util/minecraft/FluidUtils.java index 0ae751a20b..09263bb639 100644 --- a/src/Java/gtPlusPlus/core/util/minecraft/FluidUtils.java +++ b/src/Java/gtPlusPlus/core/util/minecraft/FluidUtils.java @@ -25,14 +25,64 @@ public class FluidUtils { return FluidUtils.getFluidStack("water", amount); } - public static FluidStack getlava(final int amount){ + public static FluidStack getDistilledWater(final int amount){ + return FluidUtils.getFluidStack("ic2distilledwater", amount); + } + + public static FluidStack getHotWater(final int amount) { + return FluidUtils.getFluidStack("ic2hotwater", amount); + } + + public static FluidStack getLava(final int amount){ return FluidUtils.getFluidStack("lava", amount); } + public static FluidStack getPahoehoeLava(final int amount){ + return FluidUtils.getFluidStack("ic2pahoehoelava", amount); + } + public static FluidStack getMilk(final int amount){ return FluidUtils.getFluidStack("milk", amount); } + public static FluidStack getColdCoolant(final int amount){ + return FluidUtils.getFluidStack("ic2coolant", amount); + } + + public static FluidStack getHotCoolant(final int amount){ + return FluidUtils.getFluidStack("ic2hotcoolant", amount); + } + + public static FluidStack getSteam(final int amount){ + return FluidUtils.getFluidStack("steam", amount); + } + + public static FluidStack getIC2Steam(final int amount){ + return FluidUtils.getFluidStack("ic2steam", amount); + } + + public static FluidStack getSuperHeatedSteam(final int amount){ + return FluidUtils.getFluidStack("ic2superheatedsteam", amount); + } + + @Deprecated + /** + * Do not use - Gives third tier steam - Not implemented + * @param amount + * @return + */ + public static FluidStack getHyperSteam(final int amount){ + return FluidUtils.getFluidStack("water", amount); + } + + public static FluidStack getUUA(final int amount){ + return FluidUtils.getFluidStack("uuamplifier", amount); + } + + public static FluidStack getUUM(final int amount){ + return FluidUtils.getFluidStack("ic2uumatter", amount); + } + public static FluidStack getFluidStack(final String fluidName, final int amount){ Logger.WARNING("Trying to get a fluid stack of "+fluidName); try { diff --git a/src/Java/gtPlusPlus/core/util/minecraft/MaterialUtils.java b/src/Java/gtPlusPlus/core/util/minecraft/MaterialUtils.java index ce665945c4..364430b07d 100644 --- a/src/Java/gtPlusPlus/core/util/minecraft/MaterialUtils.java +++ b/src/Java/gtPlusPlus/core/util/minecraft/MaterialUtils.java @@ -15,6 +15,9 @@ import gtPlusPlus.api.objects.Logger; import gtPlusPlus.api.objects.data.AutoMap; import gtPlusPlus.api.objects.data.TypeCounter; import gtPlusPlus.core.client.CustomTextureSet.TextureSets; +import gtPlusPlus.core.item.base.BaseItemComponent; +import gtPlusPlus.core.item.base.BaseItemComponent.ComponentTypes; +import gtPlusPlus.core.item.base.plates.BaseItemPlateHeavy; import gtPlusPlus.core.lib.CORE; import gtPlusPlus.core.material.Material; import gtPlusPlus.core.material.MaterialStack; @@ -440,6 +443,48 @@ public class MaterialUtils { } return resultList; } + + public static void generateComponentAndAssignToAMaterial(ComponentTypes aType, Material aMaterial) { + generateComponentAndAssignToAMaterial(aType, aMaterial, true); + } + + public static void generateComponentAndAssignToAMaterial(ComponentTypes aType, Material aMaterial, boolean generateRecipes) { + Item aGC; + if (aType == ComponentTypes.PLATEHEAVY) { + aGC = new BaseItemPlateHeavy(aMaterial); + } + else { + aGC = new BaseItemComponent(aMaterial, aType); + } + if (aGC != null) { + String aFormattedLangName = aType.getName(); + + if (!aFormattedLangName.startsWith(" ")) { + if (aFormattedLangName.contains("@")) { + String[] aSplit = aFormattedLangName.split("@"); + aFormattedLangName = aSplit[0] + " " + aMaterial.getLocalizedName() + " " + aSplit[1]; + } + } + + if (aFormattedLangName.equals(aType.getName())) { + aFormattedLangName = aMaterial.getLocalizedName() + aFormattedLangName; + + } + + + + Logger.MATERIALS("[Lang] "+aGC.getUnlocalizedName()+".name="+aFormattedLangName); + aMaterial.registerComponentForMaterial(aType, ItemUtils.getSimpleStack(aGC)); + } + } + + + + + + + + public static void generateSpecialDustAndAssignToAMaterial(Material aMaterial) { generateSpecialDustAndAssignToAMaterial(aMaterial, true); } diff --git a/src/Java/gtPlusPlus/core/util/minecraft/PlayerUtils.java b/src/Java/gtPlusPlus/core/util/minecraft/PlayerUtils.java index 7dd127203e..2fb7344a28 100644 --- a/src/Java/gtPlusPlus/core/util/minecraft/PlayerUtils.java +++ b/src/Java/gtPlusPlus/core/util/minecraft/PlayerUtils.java @@ -174,4 +174,8 @@ public class PlayerUtils { return false; } + public static void messageAllPlayers(String string) { + Utils.sendServerMessage(string); + } + } |