World: fix borked check

This commit is contained in:
Dylan K. Taylor 2022-07-19 17:59:53 +01:00
parent 87b840ff97
commit eccfb3bbe2
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -951,7 +951,7 @@ class World implements ChunkManager{
$blockPosition = BlockPosition::fromVector3($b);
$tile = $this->getTileAt($b->x, $b->y, $b->z);
if($tile instanceof Spawnable && ($fakeStateProperties = $tile->getRenderUpdateBugWorkaroundStateProperties($fullBlock)) !== null){
if($tile instanceof Spawnable && count($fakeStateProperties = $tile->getRenderUpdateBugWorkaroundStateProperties($fullBlock)) > 0){
$originalStateData = $blockMapping->toStateData($fullBlock->getStateId());
$fakeStateData = new BlockStateData(
$originalStateData->getName(),