Block->place() parameter refactor to make things clearer

This commit is contained in:
Dylan K. Taylor
2017-08-26 14:41:49 +01:00
parent 20f34fba53
commit 6d5620606e
44 changed files with 122 additions and 122 deletions

View File

@ -55,9 +55,9 @@ class Rail extends Flowable{
return 0.7;
}
public function place(Item $item, Block $block, Block $target, int $face, Vector3 $facePos, Player $player = null) : bool{
if(!$block->getSide(Vector3::SIDE_DOWN)->isTransparent()){
return $this->getLevel()->setBlock($block, $this, true, true);
public function place(Item $item, Block $blockReplace, Block $blockClicked, int $face, Vector3 $facePos, Player $player = null) : bool{
if(!$blockReplace->getSide(Vector3::SIDE_DOWN)->isTransparent()){
return $this->getLevel()->setBlock($blockReplace, $this, true, true);
}
return false;