Packageflare.physics.test
Classpublic class RaySphere
InheritanceRaySphere Inheritance Object
Implements flare.physics.ICollision

Detects collisions between ray and sphere colliders.



Public Methods
 MethodDefined By
  
Creates a new RaySphere object.
RaySphere
  
test(collider0:Collider, collider1:Collider, collisions:Vector.<Contact>, collisionCount:int):int
Test two colliders for collisions and contact points.
RaySphere
Constructor Detail
RaySphere()Constructor
public function RaySphere()

Creates a new RaySphere object.

Method Detail
test()method
public function test(collider0:Collider, collider1:Collider, collisions:Vector.<Contact>, collisionCount:int):int

Test two colliders for collisions and contact points. This method outputs the contacts in a plain contact list. This allows for reusing previous contacts and to test multiple tests in batch.

Parameters

collider0:Collider — The first colldier to test.
 
collider1:Collider — The second collider to test.
 
collisions:Vector.<Contact> — The contact list where the result contacts will be stored.
 
collisionCount:int — The first contacts vector index where new contacts will be placed.

Returns
int — The resulted last contact index.