Hey! I am really frustrated and that is why I am coming to the forum to write this.
I have developed a small game and wanted to test the release build on android. The problem is, that when I open the app on my phone, there is a short black screen, and it then closes instantly.
I have searched the internet far and wide, digged through my game.project
files, looked into the adb logcat
logs, scoured the APK file structure and here is what I have found.
Btw, my problem is still not fixed; help would be very much appreciated.
adb logcat
I have run adb logcat
and opened my app to see if the log shows any errors. It turns out, no! The app is launched and then killed with no apparent errors.
I have asked ChatGPT, and it says that it might be because my assets are not loaded.
APK file structure
I have then looked into the file structure of my APK file. As ChatGPT pointed out, there should be an assets folder, of which there is none. I put the assets folder in “Bundled resources” and in “custom resources” in my Defold project, but to no avail.
My game.project file looks good, and the debug build works just fine. Only the release build doesn’t work, and I do not know why.
Please help!
adb_log.txt (Line 291 to 1153): App launch to kill
game.project
app.apk
adb_log.txt (384.7 KB)
game.project.txt (1.5 KB)
app.apk.zip (1.7 MB)
SOLUTION:
I had turned on “Contentless Bundle” in the Bundle Settings in the editor. When I built the app, the project was built without content.
I turned it off, and then I also had an assets folder in my APK. It launched just fine.
Sometimes it’s the little things…