Default.png Problems

I’m trying to add a Default-Landscape.png and a Default-Landscape@2x.png to my game so that I can have a brief splash screen. Anyways, both the iPhone4 and iPhone simulators display the 1x Default.png. Also, they are displayed in the middle and zoomed in until it fits the simulator and the game loads.

  1. How can I get each iPhone simulator to use the correct Default.png and not be zooming in on it?

  2. How can I hide the status bar at the top while the Default.png is displayed?

config.lua:
[lua]application =
{
content =
{
width = 640,
height = 960,
scale = “letterbox”,
imageSuffix =
{
["@2x"] = 2,
},
},
}[/lua]
build.settings

[code]settings =
{
orientation =
{
default = “landscapeRight”,
supported = {“landscapeRight”, “landscapeLeft”},
},

iphone =
{
plist =
{
UIApplicationExitsOnSuspend = false,
CFBundleIconFile = “Icon.png”,
CFBundleIconFiles =
{
“Icon.png”,
“Icon@2x.png”,
“Icon-72.png”,
},
UIAppFonts =
{
“04B_03__.ttf”,
},
},
},
}[/code] [import]uid: 103624 topic_id: 20588 reply_id: 320588[/import]

Default-Landscape.png is only used by iPad. iPhones only use Default.png.

I you want your app to use standard resolution (320x480) and retina (640x960), then you should change your content size in config.lua to

width = 320,  
height = 480,  

You then create Default.png as 320x480 and Default@2x.png as 640x960.
Keep in mind that both images should be in portrait orientation, although the content is landscape.
If you want to hide the status bar you can add

UIStatusBarHidden=true

to the plist section in build.settings

But you say you only want to hide it *during* the splash screen?
I’m no sure if that’s possible, but you can try to add the section above to your plist, and then in your main.lua you could try adding

display.setStatusBar(display.DefaultStatusBar);

I tried adding it into my build settings, but had no luck.

Also, I’m pretty sure the Default.png works now. It loads so fast I can’t tell. What are the different types of Default.pngs? I want one to show for the two different portrait types.

build.settings

[code]settings =
{
orientation =
{
default = “landscapeRight”,
supported = {“landscapeRight”, “landscapeLeft”},
},

iphone =
{
plist =
{
UIStatusBarHidden=true,
UIApplicationExitsOnSuspend = false,
CFBundleIconFile = “Icon.png”,
CFBundleIconFiles =
{
“Icon.png”,
“Icon@2x.png”,
“Icon-72.png”,
},
UIAppFonts =
{
“04B_03__.ttf”,
},
},
},
}[/code] [import]uid: 103624 topic_id: 20588 reply_id: 80829[/import]

For iPhone there’s only one Default.png.
You can’t have different ones for different orientations.
[import]uid: 70847 topic_id: 20588 reply_id: 80833[/import]

Okay. :confused:

Anyone know why my status bar refuses to hide? [import]uid: 103624 topic_id: 20588 reply_id: 80919[/import]

Bump

No one knows how to hide the status bar on the Default.png? [import]uid: 103624 topic_id: 20588 reply_id: 80965[/import]

@IKinx, sorry mate, but I think this “thing” about the StatusBar showing over the Default.png is general IMO. Because I was looking close my apps that I do set the StatusBar Hidden but by anyway it gets showed at app`s launch, even as I said, over the Default.png. :\
Hope the masters have a solution for this too.
Cheers,
Rodrigo. [import]uid: 89165 topic_id: 20588 reply_id: 80967[/import]

I’d also rather not have to hide it each time in my scenes. A single setting (like this is supposed to be) is the best way to do it. [import]uid: 103624 topic_id: 20588 reply_id: 80968[/import]

Ah, so the simulator still shows the status bar but XCode and devices hide it. Good to know. [import]uid: 103624 topic_id: 20588 reply_id: 80970[/import]

Is there a way to do it in Corona SDK? It seems you can do it in XCode: http://stackoverflow.com/questions/900795/why-is-the-status-bar-still-showing-during-default-png. [import]uid: 103624 topic_id: 20588 reply_id: 81047[/import]

Actually, everything that is discussed in that link is what we’ve already talked about in this thread.

In my Corona apps the statusbar is always hidden, even during the display of Default.png.

I have a few questions:

  1. What kind of device are you testing your code on?
  2. Which iOS version is it running?
  3. Which Corona build are you using?

[import]uid: 70847 topic_id: 20588 reply_id: 81065[/import]

I’m using the latest stable/trial build. Also, I’m testing on the simulator and I’m running Windows 7 64-bit.

My last few questions related to the simulator. I haven’t tested it on a device yet and I was wondering if I could get the simulator to behave like the device does. [import]uid: 103624 topic_id: 20588 reply_id: 81097[/import]

As mentioned above, at the moment the statusbar in the Corona Simulator behaves differently than the device.

If you add UIStatusBarHidden=true in build.settings and display.setStatusBar(display.HiddenStatusBar); at the top of your main.lua, then
once you start testing on an actual device, you’ll see that the statusbar will be gone, even during the display of Default.png.

I’ve done this on both Android and iOS, and the statusbar is hidden at all times. [import]uid: 70847 topic_id: 20588 reply_id: 81164[/import]

If you use UIStatusBarHidden=true in the plist section in build.settings the statusbar will be hidden while you’re running your app.
Note that the Corona Simulator will still show a status bar, however if you build for device or the Xcode simulator you’ll see that the statusbar is gone.

To get the Corona Simulator to remove the status bar you just need to add display.setStatusBar(display.HiddenStatusBar); in the beginning of your main.lua.

[import]uid: 70847 topic_id: 20588 reply_id: 80969[/import]

Thanks for the help! [import]uid: 103624 topic_id: 20588 reply_id: 81171[/import]