mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-13 06:55:29 +00:00
Fixed some usages of Item constants for Blocks
only cosmetic change
This commit is contained in:
parent
66a3354b31
commit
7267f1a520
@ -1665,7 +1665,7 @@ class Level implements ChunkManager, Metadatable{
|
|||||||
}
|
}
|
||||||
|
|
||||||
$above = $this->getBlock(new Vector3($target->x, $target->y + 1, $target->z));
|
$above = $this->getBlock(new Vector3($target->x, $target->y + 1, $target->z));
|
||||||
if($above->getId() === Item::FIRE){
|
if($above->getId() === Block::FIRE){ //TODO: this should be done in Fire's onUpdate(), not with this hack
|
||||||
$this->setBlock($above, BlockFactory::get(Block::AIR), true);
|
$this->setBlock($above, BlockFactory::get(Block::AIR), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1730,7 +1730,7 @@ class Level implements ChunkManager, Metadatable{
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if($blockClicked->getId() === Item::AIR){
|
if($blockClicked->getId() === Block::AIR){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -196,7 +196,7 @@ class Furnace extends Spawnable implements InventoryHolder, Container, Nameable{
|
|||||||
$this->namedtag->MaxTime->setValue($ev->getBurnTime());
|
$this->namedtag->MaxTime->setValue($ev->getBurnTime());
|
||||||
$this->namedtag->BurnTime->setValue($ev->getBurnTime());
|
$this->namedtag->BurnTime->setValue($ev->getBurnTime());
|
||||||
$this->namedtag->BurnTicks->setValue(0);
|
$this->namedtag->BurnTicks->setValue(0);
|
||||||
if($this->getBlock()->getId() === Item::FURNACE){
|
if($this->getBlock()->getId() === Block::FURNACE){
|
||||||
$this->getLevel()->setBlock($this, BlockFactory::get(Block::BURNING_FURNACE, $this->getBlock()->getDamage()), true);
|
$this->getLevel()->setBlock($this, BlockFactory::get(Block::BURNING_FURNACE, $this->getBlock()->getDamage()), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -253,7 +253,7 @@ class Furnace extends Spawnable implements InventoryHolder, Container, Nameable{
|
|||||||
}
|
}
|
||||||
$ret = true;
|
$ret = true;
|
||||||
}else{
|
}else{
|
||||||
if($this->getBlock()->getId() === Item::BURNING_FURNACE){
|
if($this->getBlock()->getId() === Block::BURNING_FURNACE){
|
||||||
$this->getLevel()->setBlock($this, BlockFactory::get(Block::FURNACE, $this->getBlock()->getDamage()), true);
|
$this->getLevel()->setBlock($this, BlockFactory::get(Block::FURNACE, $this->getBlock()->getDamage()), true);
|
||||||
}
|
}
|
||||||
$this->namedtag->BurnTime->setValue(0);
|
$this->namedtag->BurnTime->setValue(0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user