I need a bunch of balls bouncing in 3d, in javascript. They must bounce off each other.
Here is the working code for 2d collisions, it can be added to:
[login to view URL]
I believe the 3D version of this and the equations are here, it mentions calculating Z first:
[login to view URL]
You can use the jsFiddle, but I need the Z component added.
The Z can be shown as the size of the ball (bigger=closer).
I will need to test this code to make sure the Z works right (in a 3d software) since it's hard to tell in 2d. It will take me less than 1 hour to test and verify
if you do not mind how the solution is implemented, then I can do it for you.
but if you want a manual implementation of the equations you attached look for someone else.