【Unity】Error:AAPT: error: unexpected element <property> found in <manifest><application>

1. Background

1. Unity 2021.3.9f1
2. Upgrade Max to the latest version

2. Problem description

  1. error message

AAPT: error: unexpected element found in
Insert image description here

3. Solution

  1. reason:

Upgrading Admob advertising channel to version 22.4.0 requires Android Gradle 4.2.0+

The corresponding relationship between the Android Gradle plug-in version and the Unity Gradle version. The Android official website
Insert image description here
comes with the download address of each Gradle version
2. Solution
(1) Download Gradle 6.7.1 version and replace the Unity engine D:\Unity3D\2021.3.9f1\Editor\Data\PlaybackEngines\ lib folder in the AndroidPlayer\Tools\gradle directory
Insert image description here
(2) ProjectSettings-Publishing Settings, check Custon Base Gradle Template
Insert image description here
(3) Modify classpath 'com.android.tools.build:gradle:4.2.1' Gradle plug-in version
Insert image description here

Guess you like

Origin blog.csdn.net/weixin_42186644/article/details/132996618