I want to make a car break apart as it crashes into walls. how would I go about doing this in unity?
complex script or easy in unity?
I want to make a car break apart as it crashes into walls. how would I go about doing this in unity?
complex script or easy in unity?
Knowing when to cause breakage is pretty easy, at least. Check out the Collision class, and Collider.OnCollisionEnter. With the relativeVelocity you can tell how hard a collision you have just had.
how would i get the breakage to happen?
would i need to make a animation or something
and if i wanted breakage on all sides of the cars would that mean seperate animations for every possible collision??
lol i dont understand
To make it like nature is so simple you just make a crash and then you have this part
One way to go about this is to have the various parts of the car held together by fixed joints. This joint doesn’t allow the parts to move relative to each other, but you can set a breaking force for it. If the stress on the joint is greater than the breaking force, the joint connection disappears and the two objects are separated.