ios - Game for Apple TV appears tilted on the big screen -


since few years have "iphone controller, game screen displayed on tv way of apple tv , air play" project going. it's space-shooter-maze kind of game, except there no shooting , objective steer spaceship find boss (which pic of ~1 year old son). nes game without nes.

now when run stuff first time in year or so, controller, using spritekit scene down line, tilted 90 degrees in right or left direction. "or" depends on orientation iphone 6 plus in when app starts. game takes half of tv screen - because it's tilted - , lay man can see fishy going on because text not normal horizontal text reading now, it's tilted.

did change recently, ios 8 , how hooking additional uiscreen:s work? touch project, forget how work of time again after long hiatus. experienced , know start digging?

poking around, seems app , displayed on handheld device/controller (the iphone) must/should portrait only. if app launched in landscape mode, screen display on tv "tilted", without tv being tilted... , things out of order. set portrait clicking around in target->device orientation checkboxes.

this kind of unwanted because normal video game controller held in landscape position , way used it. don't know made work differently, maybe it's iphone 6 plus landscape support @ home screen level, or maybe ios 8 or whatever.

there 2 options here.

  • design controller portrait, in design put tilted. bottom left steering cross have put top left, tilted 90 degrees right fake "landscape right" setting. might less of pain doing same thing tv screen instead.

  • continue use of real landscape mode controller, , use anti-tilt rotation setting new rotated transform of tv controller's view's transform. (i tried this, seemed needed translation well, gave up. still might work.)

update: found better solution:

  1. allow landscape right, landscape left , portrait rotations of app. (in order, if intend launch controller in landscape mode - portrait has in there.)

  2. in subclass of uiviewcontroller controls what's going on upon tv, return uiinterfaceorientationmaskportrait in supportedinterfaceorientations. tv controller must run in "portrait" mode, tv controller mean "default" mode, eye looks normal landscapish mode. landscaped tv controller mean tilted view, , don't want that. yes weird maybe logical. oh, , in subclass of uiviewcontroller hand controller, return uiinterfaceorientationmasklandscape not support portrait mode. user launches controller in portrait mode (especially on iphone other 6 plus) , if supported he/she maybe think controller can used in portrait mode, , inconvenient when playing video games.


Comments

Popular posts from this blog

dns - How To Use Custom Nameserver On Free Cloudflare? -

python - Pygame screen.blit not working -

c# - Web API response xml language -