mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-22 20:49:43 +00:00
sand will be destroyed if it falls on torch/non solid block
This commit is contained in:
parent
38ee2f8b09
commit
d005e69c1f
1 changed files with 13 additions and 4 deletions
|
|
@ -614,11 +614,20 @@ class Entity extends Position
|
||||||
}
|
}
|
||||||
if($this->speedY != 0){
|
if($this->speedY != 0){
|
||||||
$ny = $this->y + $this->speedY;
|
$ny = $this->y + $this->speedY;
|
||||||
if($this->class === ENTITY_FALLING && $support){
|
if($this->class === ENTITY_FALLING){
|
||||||
|
if($support){
|
||||||
$this->level->fastSetBlockUpdate($this->x, $this->y, $this->z, $this->data["Tile"], 0);
|
$this->level->fastSetBlockUpdate($this->x, $this->y, $this->z, $this->data["Tile"], 0);
|
||||||
$this->close();
|
$this->close();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
$id = $this->level->level->getBlockID($this->x, $this->y, $this->z);
|
||||||
|
if($id > 0 && !StaticBlock::getIsSolid($id) && !StaticBlock::getIsLiquid($id)){
|
||||||
|
$this->server->api->entity->drop($this, BlockAPI::getItem($this->data["Tile"], 0, 1));
|
||||||
|
$this->close();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
$this->y = $ny;
|
$this->y = $ny;
|
||||||
|
|
||||||
$update = true;
|
$update = true;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue