Problem:
My app has an extremly long loading time on iOS (30-40 seconds). I tested this on two iPhones (7 and 8). One time I installed the app through iTunes and the other time downloaded from the App store (Lucky Pirate - A Deck Builder on the App Store). The 30-40 seconds are spend on the launch screen and not the screen after (with the unity logo). That splash screen only lasts the 2 seconds which is the duration I set in the editor. To repeat, the launch screen shows for 30-40 seconds.
Why I think this is a bug:
- On Android the app loads instantanously, no wait time, even on older devices.
- On WebGL the app loads slower but still completes in 5-10 seconds not 30-40 seconds.
- The Android app is 22 MB, the iOS IPA file is also only 32 MB large (no idea why the app store is showing 99 MB for the app size - maybe unpacked?).
- There are no audio assets, only two large images (around 5MB each) and no other large assets listed in the build log.
What I tried to solve this issue:
- Make sure I build a release version
- I enabled “Use on-demand resources” in the editor
- I switched from a launch screen with a static image to a storyboard → no improvement.
- Tried Compression → did not work and make it even slower
- Tried to use high stripping instead of low code stripping → did not help with the speed and cause bugs in my gameplay.
More info about my setup:
- I am using the URP with a 2D game setup
- I don’t have a Mac so I use Unity Cloud to build & publish the app
- I am using Unity 2019.421f1
- I have a few static classes that load the save file and send a request to the server to check for updates. I disabled the server check and the load time stayed. I haven’t removed the save file loading because that breaks my game, but the save file is 4 KB large.
I really appreciate your help because as of now the app is basically broken on iOS.
Update: I tried it on a third device, iPhone 7 and there is no launch time. It is as perfect as on Android, just starts without delay. Why is this happening on some devices but not on all??