mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 17:59:48 +00:00
Fixed falling blocks getting moved by currents, closes #2080
This commit is contained in:
@ -189,10 +189,12 @@ abstract class Liquid extends Transparent{
|
||||
}
|
||||
|
||||
public function addVelocityToEntity(Entity $entity, Vector3 $vector) : void{
|
||||
$flow = $this->getFlowVector();
|
||||
$vector->x += $flow->x;
|
||||
$vector->y += $flow->y;
|
||||
$vector->z += $flow->z;
|
||||
if($entity->canBeMovedByCurrents()){
|
||||
$flow = $this->getFlowVector();
|
||||
$vector->x += $flow->x;
|
||||
$vector->y += $flow->y;
|
||||
$vector->z += $flow->z;
|
||||
}
|
||||
}
|
||||
|
||||
abstract public function tickRate() : int;
|
||||
|
Reference in New Issue
Block a user