Can only get one collision from collision detector



Im trying to get all the features a component collides with. However, detector.getHitFeatureB can only detect one collision even if i have placed the component to collide with four different features that are all included in the NodeListB. If i run anthing else than detector.getHitFeatureB(0) i get “Index out of bounds”

detector.Tolerance only result in “Attribute or method ‘Tolerances’ not found.”. Since it said that i needed tolerances to find be able to detect more than one collision i tried using testAllCollisions(10) but it didnt help.

Which collision it identifies between the two features that are closest to the origo point.

Am i missing something very basic here?

best regards,


If it helps, the tests/getters have to be iterative in your script. You would have to create a loop and use a frequency for testing the collisions. That is one reason why the speed of simulation can affect the test results (too fast and it might miss something or detect the collision too late).

In your case, try stopping the simulation when a collision is detected. After the simulation is stopped, change the tolerance values and use the getters to evaluate the results. If that does not help at all, just create multiple tests and make them feature-specific as needed.

I don’t have access to software or API reference atm, but double-check if your features are not merged in the containing node. And if the detector is not set to use a tolerance value then I believe the <<Tolerance>> property is dynamic in that case. There isn’t an example in the API reference? What about in vcVolumeDetector?