Added all block hardness

This commit is contained in:
Shoghi Cervantes
2015-05-31 17:25:02 +02:00
parent f3c46b12c5
commit 26c9eed82e
86 changed files with 131 additions and 676 deletions

View File

@ -45,7 +45,7 @@ class Vine extends Transparent{
}
public function getHardness(){
return 1;
return 0.2;
}
public function canPassThrough(){
@ -142,29 +142,6 @@ class Vine extends Transparent{
return false;
}
public function getBreakTime(Item $item){
if($item->isShears()){
return 0.02;
}elseif($item->isSword()){
return 0.2;
}elseif($item->isAxe()){
switch($item->isAxe()){
case Tool::TIER_WOODEN:
return 0.15;
case Tool::TIER_STONE:
return 0.075;
case Tool::TIER_IRON:
return 0.05;
case Tool::TIER_DIAMOND:
return 0.0375;
case Tool::TIER_GOLD:
return 0.025;
}
}
return 0.3;
}
public function onUpdate($type){
if($type === Level::BLOCK_UPDATE_NORMAL){
/*if($this->getSide(0)->getId() === self::AIR){ //Replace with common break method