GlowingRedstoneOre: fixed infinite recursion and crash on block update

closes #2104

The inheritance of GlowingRedstoneOre from RedstoneOre maybe should be reconsidered. They only share properties in reality.
This commit is contained in:
Dylan K. Taylor 2018-03-15 09:24:33 +00:00
parent 95fb1d1602
commit a9a55e9558

View File

@ -23,6 +23,9 @@ declare(strict_types=1);
namespace pocketmine\block;
use pocketmine\item\Item;
use pocketmine\Player;
class GlowingRedstoneOre extends RedstoneOre{
protected $id = self::GLOWING_REDSTONE_ORE;
@ -37,6 +40,14 @@ class GlowingRedstoneOre extends RedstoneOre{
return 9;
}
public function onActivate(Item $item, Player $player = null) : bool{
return false;
}
public function onNearbyBlockChange() : void{
}
public function ticksRandomly() : bool{
return true;
}