mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-09 03:06:55 +00:00
Block: get rid of getRuntimeId()
the runtime ID mapping should be non-global in case of multiple protocols.
This commit is contained in:
@ -25,6 +25,7 @@ namespace pocketmine\world\sound;
|
||||
|
||||
use pocketmine\block\Block;
|
||||
use pocketmine\math\Vector3;
|
||||
use pocketmine\network\mcpe\convert\RuntimeBlockMapping;
|
||||
use pocketmine\network\mcpe\protocol\LevelSoundEventPacket;
|
||||
|
||||
/**
|
||||
@ -43,7 +44,7 @@ class BlockPunchSound implements Sound{
|
||||
return LevelSoundEventPacket::create(
|
||||
LevelSoundEventPacket::SOUND_HIT,
|
||||
$pos,
|
||||
$this->block->getRuntimeId()
|
||||
RuntimeBlockMapping::getInstance()->toRuntimeId($this->block->getId(), $this->block->getMeta())
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user