diff options
author | Nathan Adams <dinnerbone@dinnerbone.com> | 2011-11-27 02:25:12 +0000 |
---|---|---|
committer | Nathan Adams <dinnerbone@dinnerbone.com> | 2011-11-27 02:25:12 +0000 |
commit | 24804f641924fa212705355a852c3624d6af65d0 (patch) | |
tree | 6f9bc7dae45c17d2fc71d5f350b56ea1f181c1d8 /src | |
parent | aba0bbc70f156dda47a10a0bfcf56346ad682441 (diff) | |
download | bukkit-24804f641924fa212705355a852c3624d6af65d0.tar bukkit-24804f641924fa212705355a852c3624d6af65d0.tar.gz bukkit-24804f641924fa212705355a852c3624d6af65d0.tar.lz bukkit-24804f641924fa212705355a852c3624d6af65d0.tar.xz bukkit-24804f641924fa212705355a852c3624d6af65d0.zip |
Made ItemStack .equals take into account data and enchantments
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/org/bukkit/inventory/ItemStack.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/org/bukkit/inventory/ItemStack.java b/src/main/java/org/bukkit/inventory/ItemStack.java index 18df0b73..e1adce49 100644 --- a/src/main/java/org/bukkit/inventory/ItemStack.java +++ b/src/main/java/org/bukkit/inventory/ItemStack.java @@ -200,7 +200,7 @@ public class ItemStack implements Serializable, ConfigurationSerializable { ItemStack item = (ItemStack) obj; - return item.getAmount() == getAmount() && item.getTypeId() == getTypeId(); + return item.getAmount() == getAmount() && item.getTypeId() == getTypeId() && getDurability() == item.getDurability() && getEnchantments().equals(item.getEnchantments()); } @Override |