Fix client side pseudo item entity dropped from lore book
This commit is contained in:
parent
853bde6da8
commit
81834e4e98
1 changed files with 6 additions and 4 deletions
|
@ -74,10 +74,12 @@ public class ContainerLore extends Container {
|
|||
|
||||
@Override
|
||||
public void onContainerClosed(EntityPlayer entityplayer) {
|
||||
ItemStack item = this.loreSlot.getStackInSlot(0);
|
||||
if(!entityplayer.worldObj.isRemote) {
|
||||
ItemStack item = this.loreSlot.getStackInSlot(0);
|
||||
|
||||
if (item != null) {
|
||||
entityplayer.entityDropItem(item, 1.0F);
|
||||
if (item != null) {
|
||||
entityplayer.entityDropItem(item, 1.0F);
|
||||
}
|
||||
}
|
||||
|
||||
super.onContainerClosed(entityplayer);
|
||||
|
@ -88,4 +90,4 @@ public class ContainerLore extends Container {
|
|||
return !player.isDead;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue