Straight from the Sprite kit programming guide:
The allowsRotation property determines whether forces can impart angular velocity on the body.
Question
I have a spritenode with a physics body that is affected by gravity and dynamic, however, when it hits things it rotates.
I am only using the physicsbody for the Y axis gravity, and nothing else. When it hits something horizontally, I don't want it to be affected by that thing..
How can I accomplish this?
Solution
Straight from the Sprite kit programming guide:
The allowsRotation property determines whether forces can impart angular velocity on the body.