pocketmine\block\RedstoneSource::canCalc PHP Метод

canCalc() публичный Метод

public canCalc ( )
    public function canCalc()
    {
        return $this->getLevel()->getServer()->redstoneEnabled;
    }

Usage Example

Пример #1
0
 public function canCalcTurn()
 {
     if (!parent::canCalc()) {
         return false;
     }
     if ($this->getLevel()->getServer()->getTick() != $this->getLastUpdateTime()) {
         return true;
     }
     return $this->canScheduleUpdate() ? Level::BLOCK_UPDATE_SCHEDULED : false;
 }
All Usage Examples Of pocketmine\block\RedstoneSource::canCalc