aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/xmod/eio
diff options
context:
space:
mode:
authorAlkalus <3060479+draknyte1@users.noreply.github.com>2018-05-29 16:34:22 +1000
committerAlkalus <3060479+draknyte1@users.noreply.github.com>2018-05-29 16:34:22 +1000
commit272cd6156d1dc92985b613511b4cae62ef516bb1 (patch)
tree3c3a4502e5f57473a50171eae8eec676f9f74320 /src/Java/gtPlusPlus/xmod/eio
parent45c071b2ac73abc28671bbaa087dec075e4254c0 (diff)
downloadGT5-Unofficial-272cd6156d1dc92985b613511b4cae62ef516bb1.tar.gz
GT5-Unofficial-272cd6156d1dc92985b613511b4cae62ef516bb1.tar.bz2
GT5-Unofficial-272cd6156d1dc92985b613511b4cae62ef516bb1.zip
% Changed max thread life to 300 seconds.
$ More thread safety. - Removed useless EIO tooltip variables.
Diffstat (limited to 'src/Java/gtPlusPlus/xmod/eio')
-rw-r--r--src/Java/gtPlusPlus/xmod/eio/handler/HandlerTooltip_EIO.java41
1 files changed, 0 insertions, 41 deletions
diff --git a/src/Java/gtPlusPlus/xmod/eio/handler/HandlerTooltip_EIO.java b/src/Java/gtPlusPlus/xmod/eio/handler/HandlerTooltip_EIO.java
index d04af8252b..6d50f64e6d 100644
--- a/src/Java/gtPlusPlus/xmod/eio/handler/HandlerTooltip_EIO.java
+++ b/src/Java/gtPlusPlus/xmod/eio/handler/HandlerTooltip_EIO.java
@@ -18,14 +18,6 @@ import net.minecraftforge.event.entity.player.ItemTooltipEvent;
public class HandlerTooltip_EIO {
private static Item mIngot;
- private static ItemStack mPulsatingIron;
- private static ItemStack mConductiveIron;
- private static ItemStack mRedstoneAlloy;
- private static ItemStack mElectricalSteel;
- private static ItemStack mEnergeticAlloy;
- private static ItemStack mVibrantAlloy;
- private static ItemStack mSoularium;
- private static ItemStack mDarkIron;
Class oMainClass;
Class oIngotClass;
@@ -41,16 +33,13 @@ public class HandlerTooltip_EIO {
oMainClass = Class.forName("crazypants.enderio.EnderIO");
oIngotClass = Class.forName("crazypants.enderio.material.ItemAlloy");
if (oMainClass != null && oIngotClass != null){
-
Field oAlloyField = oMainClass.getDeclaredField("itemAlloy");
oAlloyField.setAccessible(true);
Object oAlloy = oAlloyField.get(oMainClass);
-
if (oAlloy != null){
if (oIngotClass.isInstance(oAlloy) || Item.class.isInstance(oAlloy)){
mIngot = (Item) oAlloy;
}
-
}
}
}
@@ -62,36 +51,6 @@ public class HandlerTooltip_EIO {
//If the Item is an instance of ItemAlloy.class then proceed
if (event.itemStack.getItem() == mIngot || oIngotClass.isInstance(event.itemStack.getItem()) || event.itemStack.getUnlocalizedName().toLowerCase().contains("item.itemAlloy")){
- //If EIO Item Is not Null, see if the ItemStacks for the ingots are null
- //if they stacks are null, set the stack using the item set via reflection.
- //The meta data is based on the oridinals of the materials in the EIO enum.
-
- if (mElectricalSteel == null){
- mElectricalSteel = ItemUtils.simpleMetaStack(mIngot, 0, 1);
- }
- if (mEnergeticAlloy == null){
- mEnergeticAlloy = ItemUtils.simpleMetaStack(mIngot, 1, 1);
- }
- if (mVibrantAlloy == null){
- mVibrantAlloy = ItemUtils.simpleMetaStack(mIngot, 2, 1);
- }
- if (mRedstoneAlloy == null){
- mRedstoneAlloy = ItemUtils.simpleMetaStack(mIngot, 3, 1);
- }
- if (mConductiveIron == null){
- mConductiveIron = ItemUtils.simpleMetaStack(mIngot, 4, 1);
- }
- if (mPulsatingIron == null){
- mPulsatingIron = ItemUtils.simpleMetaStack(mIngot, 5, 1);
- }
- if (mDarkIron == null){
- mDarkIron = ItemUtils.simpleMetaStack(mIngot, 6, 1);
- }
- if (mSoularium == null){
- mSoularium = ItemUtils.simpleMetaStack(mIngot, 7, 1);
- }
-
-
//If stacks match, add a tooltip.
if (mIngot != null){
if (event.itemStack.getItem() == mIngot){