How to restrict physics rotation to one axis?

I have an item that I want to rotate around the Yaw axis only during the physics simulation. I set the “Restrict rotation” field in the physics part of the static mesh in my Blueprint to “Z” and it is my understanding, now the object should remain upright, whatever happens.
However, when I drop the object and it falls down on some other objects, it just rolls over as if there was no restriction at all.

What am I doing wrong?


Ah thanks a bunch, I thought that only works with two meshes. This helps indeed :slight_smile:

Hi Wallenstein,

What you want is to create an Actor Blueprint and add a physics constraint to that. Check out this thread for info on how they do it with a door: Physics Constraint Issue - World Creation - Unreal Engine Forums