NaiveBroadphase Class
Naive broadphase implementation. Does N^2 tests.
Constructor
NaiveBroadphase
()
Item Index
Properties
Methods
aabbQuery
(
Array
-
world
-
aabb
-
result
Returns all the bodies within an AABB.
Returns:
Array:
boundingRadiusCheck
(
Boolean
-
bodyA
-
bodyB
Check whether the bounding radius of two bodies overlap.
Returns:
Boolean:
canCollide
(
Boolean
-
bodyA
-
bodyB
Check whether two bodies are allowed to collide at all.
Returns:
Boolean:
setWorld
(
-
world
Set the world that we are searching for collision pairs in.
Parameters:
-
world
World
Properties
boundingVolumeType
Number
The bounding volume type to use in the broadphase algorithms. Should be set to Broadphase.AABB or Broadphase.BOUNDING_CIRCLE.
result
Array
The resulting overlapping pairs. Will be filled with results during .getCollisionPairs().