Thứ Sáu, 4 tháng 8, 2023

Fix the issue Unity android 12, 13 can not start the game

When build unity game that target android 12, 13, the game can not start. There are two things to fix this: 1. In Unity Player Settings, publish settings: - Check custom main manifest + Add property android:exported="true" to activity  - Check custom main gradle template + If using admob, add this to dependencies setting: implementation 'com.google.android.gms:play-services-ads:20.4.0' // 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...
Read More »