Fixed #1970 Breaking blocks does not remove tile entities

This commit is contained in:
Shoghi Cervantes 2014-08-25 16:55:52 +02:00
parent a0df0a8fff
commit c3b1b59118

View File

@ -874,6 +874,11 @@ class Level implements ChunkManager, Metadatable{
}
$drops = $target->getDrops($item); //Fixes tile entities being deleted before getting drops
$target->onBreak($item);
$tile = $this->getTile($target);
if($tile instanceof Tile){
$tile->close();
}
if($item instanceof Item){
$item->useOn($target);
if($item->isTool() and $item->getDamage() >= $item->getMaxDurability()){