반응형
해결법
Unity 프로젝트 파일 -> Library -> Bee -> Android -> Prj -> IL2CPP -> Gradle 경로로 들어가서
build.gradle 파일을 수정하면 됩니다.
plugins {
// If you are changing the Android Gradle Plugin version, make sure it is compatible with the Gradle version preinstalled with Unity
// See which Gradle version is preinstalled with Unity here https://docs.unity3d.com/Manual/android-gradle-overview.html
// See official Gradle and Android Gradle Plugin compatibility table here https://developer.android.com/studio/releases/gradle-plugin#updating-gradle
// To specify a custom Gradle version in Unity, go do "Preferences > External Tools", uncheck "Gradle Installed with Unity (recommended)" and specify a path to a custom Gradle version
id 'com.android.application' version '7.1.2' apply false
id 'com.android.library' version '7.1.2' apply false
classpath 'com.android.tools.build:gradle:3.4.3'
}
task clean(type: Delete) {
delete rootProject.buildDir
}
위처럼 되어 있는 코드를
buildscript {
repositories {
google()
jcenter() // 또는 mavenCentral(), 선호에 따라 다름
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.3'
}
}
plugins {
id 'com.android.application' version '7.1.2' apply false
id 'com.android.library' version '7.1.2' apply false
}
task clean(type: Delete) {
delete rootProject.buildDir
}
이렇게 수정하면 됩니다.
빌드 버전에 대한 오류가 있다면 7.1.2를 버전에 맞게 8.0.0등으로 바꿔주면 됩니다.
Unity 프로젝트 파일 -> Library -> Bee -> Android -> Prj -> IL2CPP -> Gradle->wrapper 폴더 안의
gradle-wrapper properties 파일에도 버전을 변경해줍니다.
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-all.zi
->
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-all.zi
반응형
LIST
'Unity' 카테고리의 다른 글
Input Action Asset (0) | 2024.05.30 |
---|---|
Unity Google Admob (0) | 2024.04.22 |
Character Controller move가 안될때 (0) | 2022.08.03 |
Unity Input System (0) | 2022.08.03 |
enum활용 (0) | 2022.07.05 |