← Back to Blog

Tearing a car apart: parts, joints, and detachment

Car panels tearing off and scattering after a heavy impact with a wall

The detach test: with enough force, the car stops being a single object.

A dent is only half of a crash. Hit a car hard enough and it does not just fold, it comes apart. A door swings open on a bent hinge, the bonnet buckles and lifts, a bumper tears off and tumbles down the road. The previous article covered how the body deforms and holds its shape. This one is about what happens when the body is no longer one thing.

A car is not one object

Under the skin, the car is still the single softbody network from the last article, but it is partitioned into parts: the main shell, the doors, the bonnet, the boot, the bumpers. Every mass point is tagged with the part it belongs to. Most of the time this partitioning is invisible and the whole thing behaves as one connected body. It only starts to matter when a part needs to flex, move, or leave independently of the rest.

Different regions, different rules

Tagging parts is what lets each region have its own personality. A bumper is light and floppy and is meant to crumple and pop off. The cabin is the opposite: it should stay stiff and hold its shape, the digital equivalent of a survival cell. So stiffness, damping, and mass are set per part rather than globally. The interesting connections are the ones that straddle a boundary, the links between a part and the shell it hangs from. Those carry the crash load, and their strength is what decides whether a part rides out an impact or gives way.

Joints and latches

Real parts are not glued on, they are hinged and latched. A door pivots about a vertical axis, a bonnet lifts about a horizontal one. To get that, each part is held by joint constraints that behave like hinges and latches, with angle limits that restrict motion to the axes that make physical sense. These joints sit on top of the softbody links, so a closed door both flexes with the body and swings correctly once it is free.

Detachment as damage, not a script

The thing I care most about here is that nothing is scripted. There is no animation that plays "door falls off" when a trigger fires. Instead, every joint holding a part carries a notion of health, and that health erodes under two kinds of abuse. One is violent, fast deformation, the joint being yanked hard and quickly. The other is sustained over-stretch of the part it holds, the slow tearing you get when a panel is pinned and dragged. When the accumulated damage crosses a threshold, the joint simply lets go, and the freed part receives a small parting impulse so it opens or spins away rather than dropping in place. Because it all comes out of the real forces in the real collision, the way a car sheds its parts depends entirely on how you hit it. Two crashes are never quite the same.

The clipping problem

One unglamorous detail took a surprising amount of care. The instant a part detaches, naive physics is happy to let it sink straight back through the body it was just attached to, and a door clipping through the chassis reads as broken in a way players notice immediately. The fix is a short-lived guard that keeps a freshly freed part on the correct side of its old anchor point until it has physically cleared the body. It is not exciting work, but this is the kind of thing that separates a demo from something that looks right every single time.

Author once, mirror at load

Like the rest of the physics, parts are described in data, not code. A door is defined once, with its mass, its stiffness, its joint axis, and its break behaviour, and the left and right sides share that one definition, mirrored automatically when the car loads. Authoring one side instead of two keeps the vehicle files small and, more importantly, keeps the two sides consistent, so a car does not mysteriously lose its left door more easily than its right.

Put the deforming body and the detaching parts together and a crash becomes an emergent event rather than a canned one. The last piece is the connection between the car and the road: the tyres, where every force the car can produce has to pass through a contact patch the size of your hand. That is where the series goes next.