Realistic Cardboard Box (Folding)

Hello,

I am trying to simulate a realistic corrugated box which should fold like it would in real life, and erect into a box.
Right now I am focusing on the main 4 sides (I have excluded the flaps on the top and bottom of the box for the time being).

So far I have tried to use Hinge Joints to simulate this, but when all 4 sides are linked it does not fold at all. The joints allow it to slightly fold but it does not as intended. I have tried with 3 sides instead of 4 and it works well. Does anyone know how this might work? I am currently working on a simulation to automatically erect these boxes, so I need something decently resembles its properties.

Thank you in advance.

Hi,

Do you really need physics, and joints for this?
Perhaps it’s more practical to use animations to fold, and unfold the box.

Hello,
I am trying to simulate and test an automated mechanism to manage these boxes. As such, a prepared animation would defeat the purpose. This is not supposed to be a demonstration but a physics simulation.