mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-08 02:42:58 +00:00
Finally, I can spawn AGAIN!
This commit is contained in:
@ -22,7 +22,8 @@
|
||||
namespace PocketMine\Block;
|
||||
|
||||
use PocketMine;
|
||||
use PocketMine\Item\Item as Item;
|
||||
use PocketMine\Item\Item;
|
||||
use PocketMine\Level\Level;
|
||||
|
||||
class Carpet extends Flowable{
|
||||
public function __construct($meta = 0){
|
||||
@ -63,13 +64,13 @@ class Carpet extends Flowable{
|
||||
}
|
||||
|
||||
public function onUpdate($type){
|
||||
if($type === BLOCK_UPDATE_NORMAL){
|
||||
if($type === Level::BLOCK_UPDATE_NORMAL){
|
||||
if($this->getSide(0)->getID() === self::AIR){ //Replace with common break method
|
||||
//TODO
|
||||
//ServerAPI::request()->api->entity->drop($this, Item::get($this->id, $this->meta, 1));
|
||||
$this->level->setBlock($this, new Air(), true, false, true);
|
||||
|
||||
return BLOCK_UPDATE_NORMAL;
|
||||
return Level::BLOCK_UPDATE_NORMAL;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user