diff --git a/src/pocketmine/entity/Arrow.php b/src/pocketmine/entity/Arrow.php index 4a6e41fd9..d0d08fb7a 100644 --- a/src/pocketmine/entity/Arrow.php +++ b/src/pocketmine/entity/Arrow.php @@ -141,13 +141,8 @@ class Arrow extends Projectile{ $this->motionZ *= $friction; if($this->onGround){ - $this->motionY *= -0.5; - } - - if(abs($this->motionX) < 0.01){ $this->motionX = 0; - } - if(abs($this->motionZ) < 0.01){ + $this->motionY = 0; $this->motionZ = 0; } @@ -188,7 +183,7 @@ class Arrow extends Projectile{ } public function canCollideWith(Entity $entity){ - return $entity instanceof Living; + return $entity instanceof Living and !$this->onGround; } public function spawnTo(Player $player){ diff --git a/src/pocketmine/entity/DroppedItem.php b/src/pocketmine/entity/DroppedItem.php index c6892eefd..6aaeb4aa5 100644 --- a/src/pocketmine/entity/DroppedItem.php +++ b/src/pocketmine/entity/DroppedItem.php @@ -95,13 +95,6 @@ class DroppedItem extends Entity{ $this->motionY *= -0.5; } - if(abs($this->motionX) < 0.01){ - $this->motionX = 0; - } - if(abs($this->motionZ) < 0.01){ - $this->motionZ = 0; - } - if($this->age > 6000){ $this->kill(); }