geforkt von Mirrors/Paper
SPIGOT-279: Fix all metadata being cleared for items that support blockEntityTag on material mis-match
By: Thinkofdeath <thinkofdeath@spigotmc.org>
Dieser Commit ist enthalten in:
Ursprung
3abc015fc8
Commit
34d157aca8
@ -103,13 +103,6 @@ public final class CraftItemFactory implements ItemFactory {
|
||||
case HOPPER:
|
||||
case REDSTONE_COMPARATOR:
|
||||
case FLOWER_POT_ITEM:
|
||||
if (meta instanceof CraftMetaTileEntity) {
|
||||
CraftMetaTileEntity te = (CraftMetaTileEntity) meta;
|
||||
if (te.material != material) {
|
||||
return new CraftMetaTileEntity((CraftMetaTileEntity) null, material);
|
||||
}
|
||||
return meta;
|
||||
}
|
||||
return new CraftMetaTileEntity(meta, material);
|
||||
default:
|
||||
return new CraftMetaItem(meta);
|
||||
|
@ -20,7 +20,7 @@ public class CraftMetaTileEntity extends CraftMetaItem {
|
||||
super(meta);
|
||||
this.material = material;
|
||||
|
||||
if (!(meta instanceof CraftMetaTileEntity)) {
|
||||
if (!(meta instanceof CraftMetaTileEntity) || ((CraftMetaTileEntity) meta).material != material) {
|
||||
blockEntityTag = null;
|
||||
return;
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren