Consider the following code...

cocos2d::Node* parent = cocos2d::Node::create();
cocos2d::Node* child = cocos2d::Node::create();
parent->rotate(-90.0f); // But its not affecting the child position

When I am rotating the parent node by an angle, It's not affecting the child node position. How can I get it right? Please help. Thanks.


Use setRotation() method instead of rotate()

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.