Simulator runs game, iOS doesn't. Help!?

xtrode

  • Posts: 20
I can test my game in the simulator and it runs just fine, but when I test it on my iPhone, it sends to the device but won't open past the splash screen. Most of the time no errors, but sometimes it says it does, but also still has the "Now launch game on device" window. (i've uploaded the logs from that occasion). Any advise?

I've had this issue before running it at 2x, but was able make it open by only having 1.5x or 1x, but since the Stencyl Beta 3 update, those no longer work either.

Any ideas, or thoughts are appreciated.

colburt187

  • *
  • Posts: 2394
I think you should have all the scales selected in mobile and settings, Have you arranged the art assets in atlases? It could be crashing sure to memory.

xtrode

  • Posts: 20
I uploaded them at 2x, so that's why 3x and 4x aren't included. I do have the resources divided  between the 4 atlases. It says the memory use is 58mb for 2x and 37mb for 1x.

colburt187

  • *
  • Posts: 2394
Try enabling all the scale sizes and build again, click them all in setting and in the mobile tab.

xtrode

  • Posts: 20
Still a no go. Even with all the scales enabled in both settings and the mobile tab, it doesn't open.

bobbyck

  • *
  • Posts: 124
I'm working on my first IOS project and had the exact same problem. works in simulator, not on device. It would load splash screen and then crash.

The problem for me was the assets. Check how big your "atlases" are under settings -> atlases.

Mine were 70meg at x1 and I chopped them down to 15meg at x1 and now it works fine. It was just too much to load all at once.

(Now i'm trying to figure out why a 50kb png becomes 2megs in the atlases at x1).

Hope this helps.

iii

  • *
  • Posts: 194
(Now i'm trying to figure out why a 50kb png becomes 2megs in the atlases at x1).

The memory used by the gpu has no relation to the size of the file.
Here is a formula to calculate the memory usage :

PNG image with alpha (RGBA) = width*height*4 bytes
JPG/PNG image without alpha (RGB) = width*height*3 bytes
Font (LA) = width*height*2 bytes
Greyscale image (L) = width*height*1 byte


In your case 50kb doesn't gave out any useful information.
A 512*512 PNG with alpha that is 5MB in size,
uses the same memory in gpu with a 512*512 PNG with alpha that is 20Mb in size.
They both takes 512*512*4 = 1048576 bytes (1.05MB) total memory in gpu.
The only differences from those two, is the amount of space it occupies in the storage.

bobbyck

  • *
  • Posts: 124
thanks iii.

that explains it.

750px x 750 px = 562k x 4 = 2.2.

xtrode

  • Posts: 20
Did you get all the atlases individually under 15mb or the memory use of the scenes below 15mb?

bobbyck

  • *
  • Posts: 124
i only have 1 atlas because i only have 1 scene.

at x1 its 11.5 megs. its a bit choppy the first 4-5 seconds it loads on a 2 year old ipad but then runs fine.