Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct here to familiarize yourself with the rules and how to post constructively.

  2. Unity 2022.1 is now available as the latest Tech release.
    Dismiss Notice

iPad game just rejected for non-rotating Unity splash screen

Discussion in 'iOS and tvOS' started by PuriPuri, Apr 27, 2010.

  1. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    SOLVED! The fix for my rejection was posted by jerrodputman a few posts in. Here's how to make the Unity Basic splash screen show up in the correct orientation:

    =========
    Here's my original post:


    Submitted my iPad version of my first game Elective Immortality HD last Friday, and today I got a rejection notice because the Unity splash screen does not rotate to Portrait Upside Down when it's first launched. I have autorotation logic in place to change the game orientation from Portrait to Portrait Upside-Down while in the game.

    Anything I can do to change this? I'm using Unity Indie with iPhone Basic, so I can't just change the splash screen. :(
     
  2. Lokken

    Lokken

    Joined:
    Apr 23, 2009
    Posts:
    436
    This is annoying to me.

    If you go and download 'We Rule' for iPad you will see that it offers NO orientation correction. Not only that, but if you're using the iPad in the case apple offers, you have to hold the thing 'upside down' to play the game with it; effectively making the built in stand for the case useless.

    So that got by one reviewer but suddenly a splash screen that doesn't rotate is rejected?

    Apple is really blundering lately.
     
  3. Komar Games

    Komar Games

    Joined:
    Oct 18, 2009
    Posts:
    63
    Try to submit game again, I have iPad game too, and apple approve it few days ago(I dont have splash screen rotating, only ingame)
     
  4. EricJ13

    EricJ13

    Joined:
    Feb 28, 2009
    Posts:
    346
    They rejected it over the splash screen not rotating? That's recockulous. And disturbing. My game got approved a couple of weeks or so ago and its splash screen doesn't rotate. How in the world do we make the splash screen rotate?
     
  5. mehware

    mehware

    Joined:
    Nov 19, 2007
    Posts:
    739
    I had to add in game upside down code, portrait to portrait but my logo is only right side up, of course I am also in review...

    I thought the rule was, logo could be one orientation which shows the player how to hold it.

    - Matt
     
  6. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    I did have an empty scene that loaded first with just "Loading..." in the bottom corner, and that did not auto-rotate: I started my autorotation fixedupdate in the subsequent scene. I'll change that and see if it makes it through.
     
  7. cryogee

    cryogee

    Joined:
    Aug 6, 2009
    Posts:
    119
    Sometimes a nice email to the approval team can do wonders...Just in case you havent tried it

    But be NICE...else the next app (of a random developer) they pick after your reading your email might get rejected


    :twisted:
     
  8. tatoforever

    tatoforever

    Joined:
    Apr 16, 2009
    Posts:
    4,157
    Alright, a quick dirty solution.
    Replace the splash screen with a solid colored one.
    Black, white, should do a nice job.
    Then add an in between scene with your game logo or company logo. :D
     
  9. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    Can't do that in iPhone Publishing Basic. :(
     
  10. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    I just submitted a revised version, and now I'm back in the review queue. The launch behavior is as follows now:

    -User starts app
    -Unity splash screen is shown (still shows upside down if launched from Portrait Upside-Down orientation)
    -Almost empty scene loads. It contains a GUITexture with "Loading..." on it at 0,0 on the screen. I have code in Awake() and FixedUpdate() for autorotation in that scene. There's a one-frame yield, then it loads in to the main menu for the game proper.

    It's unclear to me whether the rejection was for the Unity splash screen or my own "Loading..." GUITexture, so I'll find out soon enough I suppose.
     
  11. Unitard

    Unitard

    Joined:
    Jan 27, 2008
    Posts:
    29
    Somewhat paranoid thought, but they could be testing the Unity company to see how long it takes them to fix this issue.

    A submitted app is not compliant with one of Apple's rules, even a small and unimportant one, and fixing it is out of the developers' hands because the code responsible is not theirs, but Unity's.
     
  12. championsoftware

    championsoftware

    Joined:
    Jan 8, 2009
    Posts:
    123
    My iPad app Terrorist Zombies HD doesn't have a rotating splash screen either, and it was just approved yesterday.
     
  13. jerrodputman

    jerrodputman

    Joined:
    Jun 4, 2008
    Posts:
    181
    The launch image itself doesn't need to auto-rotate (as this is impossible, either with Unity or without), but when the game launches in either portrait or portrait upside-down, the launch image should start in the correct orientation.

    You'll need to set up a UISupportedInterfaceOrientations array key in your Info.plist to include both UIInterfaceOrientationPortrait and UIInterfaceOrientationPortraitUpsideDown. That should cause your iPad launch image to display in the correct orientation on launch.

    If this can't be done in Unity iPhone Basic, then you should file a bug with Unity, because it is most definitely a requirement now to support the 180 orientation.

    edit: Note that when you add the UISupportedInterfaceOrientations key, the next time you do a build from Unity, most likely this key will be deleted from the Info.plist file, so you'll need to re-add it every time (I've already filed a bug report for this problem).

    edit 2: If you support all four orientations, then you'll need to add all of those orientations to the UISupportedInterfaceOrientations key, and also supply a landscape launch image (which Unity iPhone Basic should already supply).

    edit 3:

    Yeah, that's not going to work, as that's the thing they rejected you for. Just follow what I said above about adding the supported orientation key, and you should get right through.
     
  14. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    That worked! You are a hero! :D I'll append that to my first post, as I'm sure others would like to know how to do that.
     
  15. ipad

    ipad

    Joined:
    Apr 4, 2010
    Posts:
    27
    function FixedUpdate(){
    //////// screen orientation
    if ((iPhoneInput.orientation == iPhoneOrientation.LandscapeLeft) (iPhoneSettings.screenOrientation != iPhoneScreenOrientation.LandscapeLeft)){
    iPhoneSettings.screenOrientation = iPhoneScreenOrientation.LandscapeLeft;
    }
    if ((iPhoneInput.orientation == iPhoneOrientation.LandscapeRight) (iPhoneSettings.screenOrientation != iPhoneScreenOrientation.LandscapeRight)){
    iPhoneSettings.screenOrientation = iPhoneScreenOrientation.LandscapeRight;
    }
    }
     
  16. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
    I have two question about this fix:
    1) Does this fix also work on an iPhone/iPod? (I don't have an iPad to test on)
    2) What do I do with the UIInterfaceOrientation key in Info.plist? Do I need to delete it or just leave it there?
     
  17. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
  18. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    A quick update: my iPad game, Elective Immortality HD, was just approved for sale today, so adding the keys to Info.plist definitely fixed the rejection issue. :)
     
  19. snicholls

    snicholls

    Joined:
    Mar 19, 2009
    Posts:
    229
    What actually do you add?
     
  20. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    You need to add a new array key in your Info.plist file -- it should look like this:



    Then you need to add two Strings to that array for your supported orientations (or four if you are supporting both landscape and portrait). It should look like this once you are done entering them:

     
  21. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
    Just confirm, this does actually work ;)
    I was very lucky to get my hands on a borrowed iPad today to test this (and the other rotation requirement) out.
     
  22. tonyd

    tonyd

    Joined:
    Jun 2, 2009
    Posts:
    1,224
    Let me get this straight, we have to write iPad games that are playable in any orientation, or Apple won't accept them?

    If true, that's simply ridiculous... almost every genre I'm working on absolutely requires horizontal (landscape) orientation.
     
  23. PuriPuri

    PuriPuri

    Joined:
    Apr 19, 2009
    Posts:
    30
    No -- if your game only supports Horizontal orientation then it must support Horizontal Left and Horizontal Right. You do not have to support all four orientations if you don't want to, but you must at least support both versions of one of them.
     
  24. tonyd

    tonyd

    Joined:
    Jun 2, 2009
    Posts:
    1,224
    Okay, that makes more sense.

    But rejecting games for a non-rotating splash screen is still a bit silly.
     
  25. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
    It isn't on the ipad since the springboard auto rotates. Its weird to start an app and its displayed upsidedown.
     
  26. acme3D

    acme3D

    Joined:
    Feb 4, 2009
    Posts:
    190
    My App was designed to run in LandscapeLeft mode.

    I tried to change the plist file by adding UISupportedInterfaceOrientationLandscapeLeft and UISupportedInterfaceOrientationLandscapeRight but now the game starts rotated 90 degrees and all interface elements are screwed up (basically you can see it in portrait mode, with interface improperly positioned)

    Has anyone experience of the plist trick and landscape mode ? Does it work ?
     
  27. PS Neville

    PS Neville

    Joined:
    Aug 28, 2009
    Posts:
    78
    I am not sure that it matters anymore: Although I initially had an iPad app approved for supporting 2 rather than 4 orientations, I just today received a rejection for not supporting all 4 orientations.

    The rejection quoted this:

    "The iPad Human Interface Guidelines state that an iPad application should be able to run in all orientations. "

    The HIG do not actually state this as a requirement, but as a recommendation, and as I mentioned another game of mine was accepted with just the two orientations. In both cases, the splash screen launches correctly.

    In any event, it seems that the Apple folks in their black box are a bit more strict about this than they were initially, at least in my own (admittedly tiny) sample size. YMMV.
     
  28. acme3D

    acme3D

    Joined:
    Feb 4, 2009
    Posts:
    190
    It seems that if the App is designed to run in landscape mode, you can do it, but you have to support both left and right landscape; the problem is to get the plist trick to work with landscape orientation as in my previous post.
     
  29. PS Neville

    PS Neville

    Joined:
    Aug 28, 2009
    Posts:
    78
    Both games I mentioned are landscape, both support (and launch in) landscape left and landscape right. One was accepted initially, but one was rejected today.

    It could be that I happened to encounter the "wrong" reviewer at Apple and that supporting both landscape views will still succeed in the future with a different reviewer, but when I used one of my allotted tech support tickets from the dev program, I was told simply to update the game to support all 4 orientations (which makes no sense for my game). The support rep specifically wrote that 2 orientations will not suffice. This is a change in my (albeit brief) experience.

    Hope it goes better for others.
     
  30. acme3D

    acme3D

    Joined:
    Feb 4, 2009
    Posts:
    190
    It seems that there is not a clear procedure for acceptance at Apple, since there are Apps with just one orientation that got accepted. And they can't pretend that things are always designed for all rotations.

    And to quote Apple's HIGs:

    * Support both variants of an orientation. For example, if your application runs only in landscape, people should be able to use it whether they’re holding the device with the Home button on the right or on the left. And, if people rotate the device 180 degrees while using your application, it’s best if you can respond by rotating your content 180 degrees.
     
  31. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    It depends on the type of application.

    Immersive (games, visual stuff): can have 1 orientation only with its Flipside one.

    Productive - Utility applications: providing content or functionality to make you more productive: have to support both or will be rejected
     
  32. PS Neville

    PS Neville

    Joined:
    Aug 28, 2009
    Posts:
    78
    What I'm attempting to convey is that this was correct for my first iPad game, but the most recent submission was rejected despite supporting 2 orientations, and the Apple tech support response was that for this game all 4 needed to be supported. The rejected app is clearly a game (a simple microgame at that), not a utility or productivity app.

    I just heard from another developer who experienced the same rejection two weeks ago, but resubmitted with the same exact binary supporting the same exact 2 orientations and was approved the second time through with no changes whatsoever.

    Thus there seems to be some inconsistency at best, or confusion and disagreement at worst, within the review team itself on the issue.
     
  33. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    Hey Guys,

    sorry but i am very confused on this. I have declared the arrays (as i understand i should do that) and also did that in two ways (one for "UIInterfaceOrientation" and one for "UISupportedInterfaceOrientation"). As you can see i have also two "Default-PNGs" in my project. But newerthless what i'm doing the splash screen will not change with the orientation of the device.

    I'm sure that i am missing something - but what?

    Thanks,

    Sandor
     

    Attached Files:

  34. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
    Just to be sure, you do know that:

    - The splashscreen will not auto-rotate. The info.plst "hack" will only fix the splashscreen startup orientation being correct.

    - The hack only works in the iPad, not on an iPhone or iPodTouch.
     
  35. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    Thanks Lukas,

    i am building for the iPad actually. And that is exactly what i was hoping to get: if you start in landscape mode take the Default-Landscape.png and if you start in portrait mode, take the Default-Portrait.png...

    I am not sure, but in the Unity player prefs you are determining a default startup mode - is that maybe the problem i am running in?

    Any help is appreciated.

    THX,

    Sandor
     
  36. Sandor

    Sandor

    Joined:
    Apr 17, 2009
    Posts:
    91
    Just answer my own question :) At least in my build for xCode from Unity iPhone there is no plist string for the "default.png" (UILaunchImageFile) created. So after i have entered a string for that, everything is working as expected. Here is the explanation for the plist:

    Cheers,

    Sandor
     
  37. yesimarobot

    yesimarobot

    Joined:
    Jun 19, 2009
    Posts:
    24
    I added UIInterfaceOrientationLandscapeLeft and UIInterfaceOrientationLandscapeRight to my Info.plist. Now when I start my app, the splash screen is oriented properly but my scenes load in portrait! Has anyone else seen similar behavior?
     
  38. AetherRepublic

    AetherRepublic

    Guest

    Joined:
    Sep 21, 2009
    Posts:
    28
    I put this into a regular Update function and it works perfectly for me.

    Also, I added the following code to my Info.plist by opening the Info.plist as a source code file:

    Code (csharp):
    1. <key>UISupportedInterfaceOrientations</key>
    2.     <array>
    3.         <string>UIInterfaceOrientationLandscapeLeft</string>
    4.         <string>UIInterfaceOrientationLandscapeRight</string>
    5.     </array>
    I start up perfectly now. Hopefully my submission will go smoothly thanks to you guys.
     
  39. PS Neville

    PS Neville

    Joined:
    Aug 28, 2009
    Posts:
    78
    For iPad, you also need to set the keyboard autorotate to false so that the outer window frame doesn't rotate. That is, if your game views rotate properly to 2 of the 4 rotations but not all 4, then you need to ensure that the outer iPad frame doesn't rotate to the 2 views you don't support.

    For example, if your game supports Portrait and PortraitUpsideDown but neither of the two landscape views, then you'd need something like this:

    Code (csharp):
    1. iPhoneKeyboard.autorotateToLandscapeLeft = false;
    2. iPhoneKeyboard.autorotateToLandscapeRight = false;
    3.  
    If you support all 4 orientations then you obviously don't need to do this.

    The summary: If your iPad game supports 2 orientations instead of 4, then you have to do all three of the following:

    (1) Make sure the game splash screen can launch in both of your 2 supported orientations by using the plist properties discussed in this thread (and if you rename your Default PNG files then you have to add the new property mentioned as well)

    (2) Make sure your game can autorotate to 2 of the 4 orientations (needed in every scene of your game)

    (3) Make sure that the outer frame doesn't appear to rotate in the 2 orientations you do not support by using the code I just posted (also needed in every scene of the game).

    Finally, if you're using OpenFeint, its new autorotate support still doesn't work in all cases as of this post, so if you use it you'll need to fall back on closing OpenFeint modals when the rotation changes and also making sure that the OpenFeint dashboard is launched in the correct orientation to begin with.

    Cheers,
    psn
     
  40. wesrm

    wesrm

    Joined:
    May 20, 2009
    Posts:
    193
    Hi AetherRepublic,

    I've had issues adding UIInterfaceOrientationLandscapeLeft and UIInterfaceOrientationLandscapeRight to my info.plist file. I added an array, but I'm curious as to what you're doing with a source code file. Are you adding the array directly to the info.plist file as suggest earlier in the thread?

    Thanks,

    Wes
     
  41. opticfibre

    opticfibre

    Joined:
    Apr 6, 2010
    Posts:
    26
    Just putting this out there as it could be a bug with unity.


    I have sorted out the launch orientation with the help of this forum and thats fine. But heres the thing...

    I have some code to detect the orientation of the iPad after launch, which then launches the correct
    menu in the correct orientation, however, if i lay the ipad flat, no orientation is detected?

    I was rejected by Apple for not supporting orientation, and i now support all four modes with my game, except FLAT that is!!!!

    :) hope they don't pull me up on that one :)
     
  42. CrystalVisions

    CrystalVisions

    Joined:
    Sep 11, 2007
    Posts:
    61
    Ok, now I am confused about this rule.

    The Elements - one of the featured apps on the Apple pages that are promoting the iPad - will only work in landscape left or landscape right. However, the splash screen does not rotate if you flip the iPad when it is loading.

    Does this violate that rule?
     
  43. Lukas H

    Lukas H

    Joined:
    Jan 16, 2009
    Posts:
    394
    No. It doesn't have to flip when loading but the loading screen has to start in the right orientation (landscape left or right in your case)
     
  44. CrystalVisions

    CrystalVisions

    Joined:
    Sep 11, 2007
    Posts:
    61
    Thanks for the clarification.
     
  45. AetherRepublic

    AetherRepublic

    Guest

    Joined:
    Sep 21, 2009
    Posts:
    28
    Hey Wes,

    I added the above code directly into the plist file which viewing it as source (text). After you do this it shows up as an array in the normal plist view.

    You can achieve the same results in the normal plist view by:
    1: making a new row and naming it UISupportedInterfaceOrientations
    2: then right click on it, make it an array
    3: click the arrow on the left so that it points downward
    4: right click your row, select add row
    5: again, right click your row, select add row
    6: then add UIInterfaceOrientationLandscapeLeft and UIInterfaceOrientationLandscapeRight to these new rows in the array

    Note that this only works for 3.2 and up because UISupportedInterfaceOrientations isn't recognized in previous Xcode versions, meaning it won't work on the iPhone until 4.0 is in the wild.

    This should handle the splash screen. Next you'll have to add code to handle in-game rotation. I used the code in my above post on an empty game object.

    -AetherRepublic
     
  46. Curious

    Curious

    Joined:
    Nov 19, 2009
    Posts:
    334
    I've added the UIInterfaceOrientationLandscapeLeft and UIInterfaceOrientationLandscapeRight hack in info.plist and it works for the splash screen but when I start my game and the scene is loaded it loads in portrait!

    I've added the code that changes the orientation in real-time (Update function) but it loads in portrait for a frame which is kind of odd and buggy!

    Any advice?
     
  47. Curious

    Curious

    Joined:
    Nov 19, 2009
    Posts:
    334
    Anyone? :?:
     
  48. frostmane

    frostmane

    Joined:
    Jun 14, 2010
    Posts:
    7
    good thread.
     
  49. Hesham

    Hesham

    Joined:
    May 29, 2008
    Posts:
    147
    @Curious

    Did you get your issue resolved? I'm facing the same here as well?
     
  50. Hesham

    Hesham

    Joined:
    May 29, 2008
    Posts:
    147
    I have the following in my plist:

    Code (csharp):
    1.  
    2. <key>UIInterfaceOrientation</key>
    3.    
    4.       <string>UIInterfaceOrientationLandscapeLeft</string>
    5.      
    6.     <key>UISupportedInterfaceOrientations</key>
    7.    <array>
    8.       <string>UIInterfaceOrientationLandscapeLeft</string>
    9.       <string>UIInterfaceOrientationLandscapeRight</string>
    10.    </array>
    11.  
    Running on the iphone, everything is ok.

    However, on the ipad, I do get the splash screen rotation, but the problem is that all the calculation made with ScreenToWorldPoint seem to return numbers that indicate I'm in portrait mode.

    Any clues?
     
unityunity