convert TileFactory to singleton

This commit is contained in:
Dylan K. Taylor
2020-04-26 01:11:30 +01:00
parent 2d55b2db1b
commit ac5cf2443e
6 changed files with 43 additions and 47 deletions

View File

@ -69,7 +69,7 @@ abstract class Tile{
public function saveNBT() : CompoundTag{
$nbt = CompoundTag::create()
->setString(self::TAG_ID, TileFactory::getSaveId(get_class($this)))
->setString(self::TAG_ID, TileFactory::getInstance()->getSaveId(get_class($this)))
->setInt(self::TAG_X, $this->pos->getFloorX())
->setInt(self::TAG_Y, $this->pos->getFloorY())
->setInt(self::TAG_Z, $this->pos->getFloorZ());