Xcode: 7.1, works on: iPhone 6s Plus
My AppDelegate.mm has the following code:
- (void) applicationDidFinishLaunching:(UIApplication*)application
---------some code
#if GAME_AUTOROTATION == kGameAutorotationUIViewController
NSLog(@"if");
[director setDeviceOrientation:kCCDeviceOrientationLandscapeLeft];
#else
NSLog(@"else");
[director setDeviceOrientation:kCCDeviceOrientationPortrait];
#endif
---------somecode
My GameConfig.h has:
#define GAME_AUTOROTATION kGameAutorotationUIViewController
My RootViewController.m has:
if GAME_AUTOROTATION == kGameAutorotationUIViewController
return ( UIInterfaceOrientationIsLandscape( interfaceOrientation ) );
My Xcode Settings:

Although the orientation of the device goes to landscape, the game appears in portrait orientation. Game screenshot:

source
share