- Home /
Kinetic Energy
Hi there,
I am making a game in which asteriods can collide with each other. What I've been trying to figure out is how to make two asteriods, both with rigidbodies and one moving, colllide in a manner where the moving one collides with the stationary one and makes that one move, using a system similar to kinetics in the real world, sort of like newton's second law of motion. I've been pondering about and experimenting with it for about a week now, and have gotten absolutely nowhere. I don't want this to be scripted, either. Any ideas?
Here is a diagram:
Just throwing out an idea: could you write a function that, OnCollisionEnter, would calculate the new velocity for each object based on their previous mass and velocity and apply it to them?
Answer by ethentianknight · Jun 02, 2016 at 02:53 PM
Try adding bounciness (tutorial below)
Add a physic material to your assets, apply it to your asteroids, then increase the bounciness until you are satisfied with the result.
https://unity3d.com/learn/tutorials/topics/physics/bouncing-ball