waylonion
waylonion

Reputation: 6976

Cocos2D with iOS6 faulty rotation

I am building an app which uses cocos2D. I developed my app using iOS 5 and now when I test with the iOS 6 simulator, the entire app is rotated. My app is supposed to be in landscape mode, but iOS 6 rotates it to portrait. Any advice would help! Thanks!

Upvotes: 2

Views: 975

Answers (1)

Ben Trengrove
Ben Trengrove

Reputation: 8769

iOS6 changed how to handle view rotation. The template projects have been updated and show how to update your project. There is more to it than just changing the addSubview to setRootViewController if you want to handle it correctly.

Cocos2d 2.0

https://github.com/cocos2d/cocos2d-iphone/blob/develop-v2/templates/Xcode4_templates/cocos2d%20iOS.xctemplate/AppDelegate.m

Cocos2d 1.1

https://github.com/cocos2d/cocos2d-iphone/blob/develop/templates/Xcode4_templates/cocos2d.xctemplate/AppDelegate.m

Upvotes: 4

Related Questions