[Issue] game always crashes on launch on Android

Hi everyone,

Recently I’ve been working on a 2d game on android, however I have released early version of it, but the issue here is that it always crashed when launched, never even loads the game. I have tried several ways to find out the root cause but to no avail.

One of the ways I have tried is ticking on a custom main gradle template, here what I added to it:

// GENERATED BY UNITY. REMOVE THIS COMMENT TO PREVENT OVERWRITING WHEN EXPORTING AGAIN

apply plugin: 'com.android.library'
**APPLY_PLUGINS**

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    // For apps targeting Android 12, add WorkManager dependency.
  constraints {
    implementation('androidx.work:work-runtime:2.7.0') {
      because '''androidx.work:work-runtime:2.1.0 pulled from
     play-services-ads has a bug using PendingIntent without
     FLAG_IMMUTABLE or FLAG_MUTABLE and will fail in Apps
     targeting S+.'''
    }
  }
**DEPS**}

android {
    compileSdkVersion **APIVERSION**
    buildToolsVersion '**BUILDTOOLS**'

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }

    defaultConfig {
        minSdkVersion **MINSDKVERSION**
        targetSdkVersion **TARGETSDKVERSION**
        ndk {
            abiFilters **ABIFILTERS**
        }
        versionCode **VERSIONCODE**
        versionName '**VERSIONNAME**'
        consumerProguardFiles 'proguard-unity.txt'**USER_PROGUARD**
    }

    lintOptions {
        abortOnError false
    }

    aaptOptions {
        noCompress = ['.ress', '.resource', '.obb'] + unityStreamingAssets.tokenize(', ')
        ignoreAssetsPattern = "!.svn:!.git:!.ds_store:!*.scc:.*:!CVS:!thumbs.db:!picasa.ini:!*~"
    }**PACKAGING_OPTIONS**
}**REPOSITORIES**
**IL_CPP_BUILD_SETUP**
**SOURCE_BUILD_SETUP**
**EXTERNAL_SOURCES**

This is the error from Android logcat every time I have tried launching the game:

2023/04/29 16:19:21.720 9717 9740 Error CRASH Tombstone written to: /storage/emulated/0/Android/data/com.BucheeriProductions.HungerStreetMission/files/tombstone_02
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime FATAL EXCEPTION: UnityMain
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Process: com.BucheeriProductions.HungerStreetMission, PID: 9717
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime java.lang.Error: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Version '2020.3.47f1 (5ef4f5b5e2d4)', Build type 'Release', Scripting Backend 'il2cpp', CPU 'armeabi-v7a'
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Build fingerprint: 'samsung/a3corexx/a3core:12/SP1A.210812.016/A032FXXU2BWC3:user/release-keys'
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Revision: '0'
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime ABI: 'arm'
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Timestamp: 2023-04-29 16:19:21+0300
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime pid: 9717, tid: 9740, name: UnityMain  >>> com.BucheeriProductions.HungerStreetMission <<<
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime uid: 10001
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x6a
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime Cause: null pointer dereference
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     r0  00000060  r1  cb564ea0  r2  0000008c  r3  00000040
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     r4  caa3f384  r5  caa21aa0  r6  bc6db3a0  r7  c071c050
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     r8  bc6db3a0  r9  00000003  r10 bc6fd280  r11 ca0d36a0
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     ip  f0e24944  sp  ca0d3670  lr  cac69a7f  pc  cac8f50a
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime backtrace:
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #00 pc 000cf50a  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #01 pc 00750f30  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libil2cpp.so (BuildId: bc9bfce1e8af75482731491ab59efa9c7eef0c15)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #02 pc 000d94f0  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libil2cpp.so (BuildId: bc9bfce1e8af75482731491ab59efa9c7eef0c15)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #03 pc 0017c9f0  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libil2cpp.so (BuildId: bc9bfce1e8af75482731491ab59efa9c7eef0c15)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #04 pc 001aa3ad  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #05 pc 001ac699  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #06 pc 001ac60b  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #07 pc 001df33b  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #08 pc 001bd94d  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #09 pc 001bdc17  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #10 pc 001bd8f7  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #11 pc 001ea34d  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #12 pc 001ea291  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #13 pc 001ea233  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #14 pc 001566ef  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #15 pc 001568df  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #16 pc 001564a9  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #17 pc 00156547  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #18 pc 001562ff  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #19 pc 00156eb7  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #20 pc 0015731d  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #21 pc 00200397  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #22 pc 0021001d  /data/app/~~ewZWMi4V2m8-ZJQQAeTp4g==/com.BucheeriProductions.HungerStreetMission-LjrbxxlVONHbRlAKoQJXfQ==/lib/arm/libunity.so (BuildId: cdff0dc27d3d79b25c82b8b7c3ff097d0ceb46cc)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime       #23 pc 000f3a8d  /apex/com.android.art/lib/libart.so (BuildId: 19d288d67da9080d0f9ea13d2970cc15)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0xcf50a(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libil2cpp.0x750f30(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libil2cpp.0xd94f0(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libil2cpp.0x17c9f0(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1aa3ad(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1ac699(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1ac60b(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1df33b(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1bd94d(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1bdc17(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1bd8f7(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1ea34d(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1ea291(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1ea233(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1566ef(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1568df(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1564a9(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x156547(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x1562ff(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x156eb7(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x15731d(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x200397(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libunity.0x21001d(Native Method)
2023/04/29 16:19:21.723 9717 9740 Error AndroidRuntime     at libart.0xf3a8d(Native Method)

This is the Android Manifest:

<?xml version="1.0" encoding="utf-8"?>
<!-- GENERATED BY UNITY. REMOVE THIS COMMENT TO PREVENT OVERWRITING WHEN EXPORTING AGAIN-->
<manifest
    xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.unity3d.player"
    xmlns:tools="http://schemas.android.com/tools">
    <application>
        <activity android:name="com.unity3d.player.UnityPlayerActivity"
                  android:theme="@style/UnityThemeSelector">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
            <meta-data android:name="unityplayer.UnityActivity" android:value="true" />
        </activity>
    </application>
</manifest>

Use development player to get more information

Okay I used the Adb.exe and this is what I got after attempting to launch the app:

https://pastebin.com/vWyzrvEB

That’s not development player, it still says you’re using Release. Development checkbox is in Build Settings window in Unity editor