Hi there,
I am developing my first game via Unity. It should run under Android and iOS. I have the following issue - once LoadScene is reached, the app freezes. I use SceneManager.LoadScene("02"); to load the second scene.
Few notes:
I use Unity 2019.2 atm, however I have exactly the same issue under 2018 (this is why I decided to switch to 2019)
All scenes are added to the build
I have made very simple project - just two scenes, I can switch from 01 to 02 via button.
I tried variety of options e.g. scripting backend Mono / IL2CPP, Split APKs by target arch. and etc. - no luck.
Important note - all above is true in case I click on BUILD only. In case I do BUILD and RUN (with my device connected to the PC), the app runs successfully.
You have probably enabled “Split application Binary” option in the Player Settings. See this page for more information Unity - Manual: APK expansion files
This creates an .obb file together with your application. When you do “Build and Run”, Unity automatically uploads obb file to your device, however when you install the apk manually, you have to add obb file as well. You can read more about how the obb file should be named and where it should be placed here APK Expansion Files | Android Developers. Alternatively just disabling “Split Application Binary” option should work for you as well.
Thanks, @JuliusM you are correct. This was indeed the issue. In fact my issue was identical to the one I found in the previous post I cited, however I wrongly misinterpreted the option with another one “Split by Architecture”, which basically splits apk to 32 and 64 executable. To sum up, my issue is basically with Unity interface and options :).
Anyway - thanks for the help!