- Home /
How can I destroy a object(like house) with a bomb?
I want to use a bomb to destroy a house I received from the Asset Store How do I code the bomb?
I use the Add Rigidbody and use gravity but I got this error Non-convex MeshCollider with non-kinematic Rigidbody is no longer supported since Unity 5. If you want to use a non-convex mesh either make the Rigidbody kinematic or remove the Rigidbody component.
So I need another way
Comment
Set the mesh collider to convex, or set rigidbody to IsKinematic (which might make the rigidbody not work), which is good in your case, since the bomb should be too heavy to move or carry, if it can destroy a house... You can use rigidbody.AddExplosionForce()
to create a splash-damage like bomb. @iodide9435