diff options
| author | OnyxDarkKnight <sor1n.iliutza16@gmail.com> | 2014-04-15 22:41:43 +0300 |
|---|---|---|
| committer | OnyxDarkKnight <sor1n.iliutza16@gmail.com> | 2014-04-15 22:41:43 +0300 |
| commit | 4b8b13b34d7a8fd0ee7c7b13f11be9c2bf3b5d18 (patch) | |
| tree | b49bc483d576ec3abeb2e18523e4511ecce353d3 /eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util | |
| parent | 86398ed60db321f86e8d98f191107fdac2c93760 (diff) | |
More 1.7 stuff
Diffstat (limited to 'eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util')
| -rw-r--r-- | eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelryNBT.java | 6 | ||||
| -rw-r--r-- | eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelrycraftUtil.java | 9 |
2 files changed, 9 insertions, 6 deletions
diff --git a/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelryNBT.java b/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelryNBT.java index 90c68d0..d76c84e 100644 --- a/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelryNBT.java +++ b/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelryNBT.java @@ -341,13 +341,13 @@ public class JewelryNBT public static boolean isJewelX(ItemStack stack, ItemStack jewel) { - if(jewel(stack) != null && jewel(stack) == jewel && jewel(stack).getItemDamage() == jewel.getItemDamage()) return true; + if(jewel(stack) != null && jewel(stack).getItem() == jewel.getItem() && jewel(stack).getItemDamage() == jewel.getItemDamage()) return true; return false; } public static boolean isModifierX(ItemStack stack, ItemStack modifier) { - if(modifier(stack) != null && modifier(stack) == modifier && modifier(stack).getItemDamage() == modifier.getItemDamage()) return true; + if(modifier(stack) != null && modifier(stack).getItem() == modifier.getItem() && modifier(stack).getItemDamage() == modifier.getItemDamage()) return true; return false; } @@ -361,7 +361,7 @@ public class JewelryNBT public static boolean isIngotX(ItemStack stack, ItemStack ingot) { - if(ingot(stack) != null && ingot(stack) == ingot && ingot(stack).getItemDamage() == ingot.getItemDamage()) return true; + if(ingot(stack) != null && ingot(stack).getItem() == ingot.getItem() && ingot(stack).getItemDamage() == ingot.getItemDamage()) return true; return false; } diff --git a/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelrycraftUtil.java b/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelrycraftUtil.java index 738f9b5..271f6f9 100644 --- a/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelrycraftUtil.java +++ b/eclipse/Jewelrycraft/common/darkknight/jewelrycraft/util/JewelrycraftUtil.java @@ -1,11 +1,13 @@ package darkknight.jewelrycraft.util; import java.util.ArrayList; +import java.util.HashMap; import java.util.Iterator; import java.util.Random; import net.minecraft.init.Blocks; import net.minecraft.init.Items; +import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraftforge.oredict.OreDictionary; import darkknight.jewelrycraft.item.ItemList; @@ -17,6 +19,7 @@ public class JewelrycraftUtil public static ArrayList<ItemStack> jewelry = new ArrayList<ItemStack>(); public static ArrayList<ItemStack> metal = new ArrayList<ItemStack>(); public static ArrayList<String> jamcraftPlayers = new ArrayList<String>(); + public static HashMap<String,Item> liquids = new HashMap<String,Item>(); public static Random rand = new Random(); public static void addStuff() @@ -102,7 +105,7 @@ public class JewelrycraftUtil while (i.hasNext()) { ItemStack temp = i.next(); - if (temp.equals(item) && temp.getItemDamage() == item.getItemDamage()) + if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage()) return true; } return false; @@ -115,7 +118,7 @@ public class JewelrycraftUtil while (i.hasNext()) { ItemStack temp = i.next(); - if (temp.equals(item) && temp.getItemDamage() == item.getItemDamage()) + if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage()) return true; } return false; @@ -128,7 +131,7 @@ public class JewelrycraftUtil while (i.hasNext()) { ItemStack temp = i.next(); - if (temp.equals(item) && temp.getItemDamage() == item.getItemDamage()) + if (temp.getItem() == item.getItem() && temp.getItemDamage() == item.getItemDamage()) return true; } return false; |
