Search Unity

weird problem - must install to Android twice for game to work

Discussion in 'Android' started by davidcox70, Jul 25, 2019.

  1. davidcox70


    Oct 19, 2016

    When I build and deploy to Android, the game crashes immediately on launch - i.e. does not get as far as running Unity scripts. If I install the game a second time without changing anything, it works perfectly!

    For example, if I uninstall any previous build, then build the game, install to Android, install to Android a second time, it will work perfectly. If I skip that second install, it will not run. Any subsequent builds, even with different code, will work first time so long as the previous build is not uninstalled.

    Same is true whether I use "build and run" from Unity, or whether I build to a local folder and use "ADB Install" to do the deployment. There are no build errors. Problems are unaffected by phone and PC reboots.

    I've tried with versions 2019.1.10f1 and 2019.1.11f1. I'm using the SDK and NDK bundled with Unity as installed via Unity Hub. Scripting backend is IL2CPP. Target hardware has ARMv7, ARM64 and X86 enabled. (also tried without x86). Gradle build. Samsung S8 G950 test device.

    Anyone come across this?

    Last edited: Jul 25, 2019