mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 19:02:59 +00:00
Added Item->getBlockToolType()
This commit is contained in:
@ -23,12 +23,18 @@ declare(strict_types=1);
|
||||
|
||||
namespace pocketmine\item;
|
||||
|
||||
use pocketmine\block\BlockToolType;
|
||||
|
||||
class Shovel extends TieredTool{
|
||||
|
||||
public function isShovel(){
|
||||
return $this->tier;
|
||||
}
|
||||
|
||||
public function getBlockToolType() : int{
|
||||
return BlockToolType::TYPE_SHOVEL;
|
||||
}
|
||||
|
||||
public function getAttackPoints() : int{
|
||||
return self::getBaseDamageFromTier($this->tier) - 3;
|
||||
}
|
||||
|
Reference in New Issue
Block a user