diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBanner.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBanner.java index 994b9aaac8..bdf74baa84 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBanner.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBanner.java @@ -27,6 +27,7 @@ public class CraftMetaBanner extends CraftMetaItem implements BannerMeta { CraftMetaBanner(CraftMetaItem meta) { super(meta); + blockEntityTag = null; if (!(meta instanceof CraftMetaBanner)) { return; @@ -39,6 +40,7 @@ public class CraftMetaBanner extends CraftMetaItem implements BannerMeta { CraftMetaBanner(NBTTagCompound tag) { super(tag); + blockEntityTag = null; if (!tag.hasKey("BlockEntityTag")) { return; @@ -59,6 +61,7 @@ public class CraftMetaBanner extends CraftMetaItem implements BannerMeta { CraftMetaBanner(Map map) { super(map); + blockEntityTag = null; String baseStr = SerializableMeta.getString(map, BASE.BUKKIT, true); if (baseStr != null) { diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java index f666713461..c25d081919 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java @@ -204,7 +204,7 @@ class CraftMetaItem implements ItemMeta, Repairable { private Map enchantments; private int repairCost; private final NBTTagList attributes; - private final NBTTagCompound blockEntityTag; + protected NBTTagCompound blockEntityTag; CraftMetaItem(CraftMetaItem meta) { if (meta == null) { @@ -556,7 +556,7 @@ class CraftMetaItem implements ItemMeta, Repairable { && (this.hasLore() ? that.hasLore() && this.lore.equals(that.lore) : !that.hasLore()) && (this.hasAttributes() ? that.hasAttributes() && this.attributes.equals(that.attributes) : !that.hasAttributes()) && (this.hasRepairCost() ? that.hasRepairCost() && this.repairCost == that.repairCost : !that.hasRepairCost()) - && (this.blockEntityTag != null ? that.blockEntityTag != null && this.blockEntityTag.equals(this.blockEntityTag) : that.blockEntityTag == null); + && (this.blockEntityTag != null ? that.blockEntityTag != null && this.blockEntityTag.equals(that.blockEntityTag) : that.blockEntityTag == null); } /**