mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 02:42:58 +00:00
Automate creation and deletion of Tiles for appropriate blocks
closes #880
This commit is contained in:
@ -1869,6 +1869,11 @@ class Level implements ChunkManager, Metadatable{
|
||||
if(!$hand->place($item, $blockReplace, $blockClicked, $face, $clickVector, $player)){
|
||||
return false;
|
||||
}
|
||||
$tile = $this->getTile($hand);
|
||||
if($tile !== null){
|
||||
//TODO: seal this up inside block placement
|
||||
$tile->copyDataFromItem($item);
|
||||
}
|
||||
|
||||
if($playSound){
|
||||
$this->broadcastLevelSoundEvent($hand, LevelSoundEventPacket::SOUND_PLACE, $hand->getRuntimeId());
|
||||
|
Reference in New Issue
Block a user