LockedAxisMode Has No Effect in C++
I am trying to constrain physics. In blueprint it works fine but I can't get it to work in C++.
I have a USphereComponent that I'm creating:
And configuring the physics state:
The only thing that isn't working is the locked axis. Am I missing a step somewhere?
The LockedAxisMode stuff is all performed as part of the initialization for the FBodyInstance that is part of the USphereComponent (and other shapes). In 4.5 and earlier, you can force the locked axis mode to update by re-calling the DOF Lock initializer, for instance:
There was a recent patch that adds a new setter function that does exactly the same thing. It will probably be in 4.6:
Follow this question
Once you sign in you will be able to subscribe for any updates here