Dynamic BVH doesn't update the tree anymore when calling set_pairable
with no parameter change.
Also modified Godot Physics broadphase to create objects directly with
pairable (static) set correctly to make use of this optimization for the
BVH broadphase.
Note: Octree broadphase doesn't use this optimization because it forces
an update on move, so passing the proper AABB and static parameters on
creation would cause the tree to update twice.
When set_static is called on a newly added object, the forced collision
check in BVH set_pairable was using an empty AABB, which caused
unnecessary collision checks at the origin, then a call to move was
checking again at the right position.
These changes ensure broadphase objects are added to the BVH tree with
proper AABB so collision checks are correctly done right away.
Octree & Basic broadphase trees are not affected by these changes.
Complete rewrite of spatial partitioning using a bounding volume hierarchy rather than octree.
Switchable in project settings between using octree or BVH for rendering and physics.