In Unity, I have trigger colliders and catch the OnTriggerStay (Collider other) events.
When two colliders touch, how can I make the Force Vector break apart?
In the example below, I have a sphere and a box collider touching each other. The OnTriggerStay is called for the sphere.
I can not use the center positions of the transformations to get a direction because this does not give a very good force vector:
And I do not think I can use the Collider.ClosestPointOnBounds to find the position of the box touch, since the point I'm looking at from (center of the sphere) could be inside the box collider itself, which is me, As I understand it, simply return to the middle again becomes the sphere. I could not dissolve a force vector from it.