mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-07 10:22:56 +00:00
Merge branch 'next-major' into modern-world-support
This commit is contained in:
@ -1904,11 +1904,9 @@ class World implements ChunkManager{
|
||||
public function getCollidingEntities(AxisAlignedBB $bb, ?Entity $entity = null) : array{
|
||||
$nearby = [];
|
||||
|
||||
if($entity === null || $entity->canCollide){
|
||||
foreach($this->getNearbyEntities($bb, $entity) as $ent){
|
||||
if($ent->canBeCollidedWith() && ($entity === null || $entity->canCollideWith($ent))){
|
||||
$nearby[] = $ent;
|
||||
}
|
||||
foreach($this->getNearbyEntities($bb, $entity) as $ent){
|
||||
if($ent->canBeCollidedWith() && ($entity === null || $entity->canCollideWith($ent))){
|
||||
$nearby[] = $ent;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user