mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-05 17:36:12 +00:00
RuntimeBlockMapping is now a singleton instead of static class
this prepares for a fully dynamic block mapper, as well as allowing a small performance improvement to chunk encoding by eliding the constant lazy-init checks.
This commit is contained in:
@ -111,7 +111,7 @@ class Block{
|
||||
* @internal
|
||||
*/
|
||||
public function getRuntimeId() : int{
|
||||
return RuntimeBlockMapping::toStaticRuntimeId($this->getId(), $this->getMeta());
|
||||
return RuntimeBlockMapping::getInstance()->toStaticRuntimeId($this->getId(), $this->getMeta());
|
||||
}
|
||||
|
||||
public function getMeta() : int{
|
||||
|
Reference in New Issue
Block a user