I developed a game supports only landscape mode for upper than ios 4.3 devices.
the application has gamecenter implemented and crashed during the test on ios 6 devices because gamecenter login screen doesn’t support landscape mode in ios 6.
so I fixed the problem adding below code into appdelegate.m and got worked but now application displays totally wired(displays portrait upside down) on devices below ios6(ios5 etc)
-(NSUInteger)application:(UIApplication *)application supportedInterfaceOrientationsForWindow:(UIWindow *)window
{
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
return UIInterfaceOrientationMaskAll;
else // iphone
return UIInterfaceOrientationMaskAllButUpsideDown;
}
use
xcode:4.5
cocos2d v1.0.1
please help me to solve this problem
Add given class in your project