Previous Up Next

M3testColl
Collision test between sub-trees A and B.
If A (resp B) is a sub-tree of B (resp A), the test is performed between sub-tree A (resp B) and sub-tree B (resp A) less sub-tree A (resp B).
The collision test is performed on the displacement of A indicated by the given vector (expressed in the global space)..

Returns a nil value if there is no collision, otherwise returns the two objects which collide as well as the two vectors (integer values):

[H3d H3d [I I I] [I I I]] M3testColl (
S3d _session_
H3d _A_
H3d _B_
[I I I] _translation_
I _distance_
)
Parameters

_session_
3D Session
_A_
A Object
_B_
B Object
_translation_
Translation vector of A
_distance_
distance of collision (the system will keep this distance between objects)
Return value

Two objects in collision with the associated vectors, otherwise nil