※New Tools' durability system
fix some tool type
This commit is contained in:
parent
9147026830
commit
d99134c803
4 changed files with 15 additions and 2 deletions
|
|
@ -47,7 +47,7 @@ class Cobweb extends Flowable{
|
|||
}
|
||||
|
||||
public function getToolType(){
|
||||
return Tool::TYPE_SWORD;
|
||||
return Tool::TYPE_SHEARS;
|
||||
}
|
||||
|
||||
public function onEntityCollide(Entity $entity){
|
||||
|
|
|
|||
|
|
@ -22,6 +22,7 @@
|
|||
namespace pocketmine\block;
|
||||
|
||||
use pocketmine\item\Item;
|
||||
use pocketmine\item\Tool;
|
||||
use pocketmine\level\Level;
|
||||
use pocketmine\Player;
|
||||
|
||||
|
|
@ -79,6 +80,11 @@ class TallGrass extends Flowable{
|
|||
return false;
|
||||
}
|
||||
|
||||
public function getToolType()
|
||||
{
|
||||
return Tool::TYPE_SHEARS;
|
||||
}
|
||||
|
||||
public function getDrops(Item $item) : array {
|
||||
if(mt_rand(0, 15) === 0){
|
||||
return [
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@
|
|||
|
||||
namespace pocketmine\block;
|
||||
|
||||
use pocketmine\item\Tool;
|
||||
|
||||
class Tripwire extends Solid {
|
||||
|
||||
protected $id = self::TRIPWIRE;
|
||||
|
|
@ -32,4 +34,9 @@ class Tripwire extends Solid {
|
|||
public function getName() : string {
|
||||
return "Tripwire";
|
||||
}
|
||||
|
||||
public function getToolType()
|
||||
{
|
||||
return Tool::TYPE_SHEARS;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -165,6 +165,6 @@ class Vine extends Transparent{
|
|||
}
|
||||
|
||||
public function getToolType(){
|
||||
return Tool::TYPE_AXE;
|
||||
return Tool::TYPE_SHEARS;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue