- Home /
object goes through another object error
I have a ball(shpere) which is shot towards a box(cube) using physics. If the force of the shot is small, the ball hits the box and bounces back, but if the force of the shot is bigger it goes through the box.
How can I stop this?
Thank you.
Have you modified the $$anonymous$$aterials? You know, change the bounciness and such??
Also sometimes unity can have a problem with the speed(way to fast, frame skips collision because of the speed) of an object and recognizing a collision.
you could try adding a rigidbody to the cube or sphere and making the collision detection continuous.
This is called frame miss and cannot be avoided. You can lower the amount of miss but you won't be 100% accurate. Your only solution is to use raycast at high velocity objects.
Answer by unimechanic · Jan 08, 2013 at 09:54 PM
Try this script to avoid fast-moving objects go through other objects: