feat: updated engine version to 4.4-rc1
This commit is contained in:
parent
ee00efde1f
commit
21ba8e33af
5459 changed files with 1128836 additions and 198305 deletions
|
|
@ -33,6 +33,10 @@
|
|||
<meta-data
|
||||
android:name="org.godotengine.editor.version"
|
||||
android:value="${godotEditorVersion}" />
|
||||
<!-- Records the rendering method used by the Godot engine -->
|
||||
<meta-data
|
||||
android:name="org.godotengine.rendering.method"
|
||||
android:value="${godotRenderingMethod}"/>
|
||||
|
||||
<activity
|
||||
android:name=".GodotApp"
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ allprojects {
|
|||
mavenCentral()
|
||||
gradlePluginPortal()
|
||||
maven { url "https://plugins.gradle.org/m2/" }
|
||||
maven { url "https://s01.oss.sonatype.org/content/repositories/snapshots/"}
|
||||
|
||||
// Godot user plugins custom maven repos
|
||||
String[] mavenRepos = getGodotPluginsMavenRepos()
|
||||
|
|
@ -28,6 +29,8 @@ allprojects {
|
|||
configurations {
|
||||
// Initializes a placeholder for the devImplementation dependency configuration.
|
||||
devImplementation {}
|
||||
// Initializes a placeholder for the monoImplementation dependency configuration.
|
||||
monoImplementation {}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
|
@ -41,9 +44,9 @@ dependencies {
|
|||
} else {
|
||||
// Godot gradle build mode. In this scenario this project is the only one around and the Godot
|
||||
// library is available through the pre-generated godot-lib.*.aar android archive files.
|
||||
debugImplementation fileTree(dir: 'libs/debug', include: ['*.jar', '*.aar'])
|
||||
devImplementation fileTree(dir: 'libs/dev', include: ['*.jar', '*.aar'])
|
||||
releaseImplementation fileTree(dir: 'libs/release', include: ['*.jar', '*.aar'])
|
||||
debugImplementation fileTree(dir: 'libs/debug', include: ['**/*.jar', '*.aar'])
|
||||
devImplementation fileTree(dir: 'libs/dev', include: ['**/*.jar', '*.aar'])
|
||||
releaseImplementation fileTree(dir: 'libs/release', include: ['**/*.jar', '*.aar'])
|
||||
}
|
||||
|
||||
// Godot user plugins remote dependencies
|
||||
|
|
@ -59,6 +62,18 @@ dependencies {
|
|||
if (pluginsBinaries != null && pluginsBinaries.size() > 0) {
|
||||
implementation files(pluginsBinaries)
|
||||
}
|
||||
|
||||
// Automatically pick up local dependencies in res://addons
|
||||
String addonsDirectory = getAddonsDirectory()
|
||||
if (addonsDirectory != null && !addonsDirectory.isBlank()) {
|
||||
implementation fileTree(dir: "$addonsDirectory", include: ['*.jar', '*.aar'])
|
||||
}
|
||||
|
||||
// .NET dependencies
|
||||
String jar = '../../../../modules/mono/thirdparty/libSystem.Security.Cryptography.Native.Android.jar'
|
||||
if (file(jar).exists()) {
|
||||
monoImplementation files(jar)
|
||||
}
|
||||
}
|
||||
|
||||
android {
|
||||
|
|
@ -90,7 +105,10 @@ android {
|
|||
abiFilters export_abi_list
|
||||
}
|
||||
|
||||
manifestPlaceholders = [godotEditorVersion: getGodotEditorVersion()]
|
||||
manifestPlaceholders = [
|
||||
godotEditorVersion: getGodotEditorVersion(),
|
||||
godotRenderingMethod: getGodotRenderingMethod()
|
||||
]
|
||||
|
||||
// Feel free to modify the application id to your own.
|
||||
applicationId getExportPackageName()
|
||||
|
|
@ -154,6 +172,10 @@ android {
|
|||
}
|
||||
}
|
||||
|
||||
buildFeatures {
|
||||
buildConfig = true
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
|
||||
debug {
|
||||
|
|
@ -191,6 +213,13 @@ android {
|
|||
}
|
||||
}
|
||||
|
||||
flavorDimensions 'edition'
|
||||
|
||||
productFlavors {
|
||||
standard {}
|
||||
mono {}
|
||||
}
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
manifest.srcFile 'AndroidManifest.xml'
|
||||
|
|
@ -206,75 +235,38 @@ android {
|
|||
|
||||
applicationVariants.all { variant ->
|
||||
variant.outputs.all { output ->
|
||||
output.outputFileName = "android_${variant.name}.apk"
|
||||
String filenameSuffix = variant.flavorName == "mono" ? variant.name : variant.buildType.name
|
||||
output.outputFileName = "android_${filenameSuffix}.apk"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
task copyAndRenameDebugApk(type: Copy) {
|
||||
task copyAndRenameBinary(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
|
||||
from "$buildDir/outputs/apk/debug/android_debug.apk"
|
||||
into getExportPath()
|
||||
rename "android_debug.apk", getExportFilename()
|
||||
}
|
||||
String exportPath = getExportPath()
|
||||
String exportFilename = getExportFilename()
|
||||
String exportEdition = getExportEdition()
|
||||
String exportBuildType = getExportBuildType()
|
||||
String exportBuildTypeCapitalized = exportBuildType.capitalize()
|
||||
String exportFormat = getExportFormat()
|
||||
|
||||
task copyAndRenameDevApk(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
boolean isAab = exportFormat == "aab"
|
||||
boolean isMono = exportEdition == "mono"
|
||||
String filenameSuffix = isAab ? "${exportEdition}-${exportBuildType}" : exportBuildType
|
||||
if (isMono) {
|
||||
filenameSuffix = isAab ? "${exportEdition}-${exportBuildType}" : "${exportEdition}${exportBuildTypeCapitalized}"
|
||||
}
|
||||
|
||||
from "$buildDir/outputs/apk/dev/android_dev.apk"
|
||||
into getExportPath()
|
||||
rename "android_dev.apk", getExportFilename()
|
||||
}
|
||||
String sourceFilename = isAab ? "build-${filenameSuffix}.aab" : "android_${filenameSuffix}.apk"
|
||||
String sourceFilepath = isAab ? "$buildDir/outputs/bundle/${exportEdition}${exportBuildTypeCapitalized}/$sourceFilename" : "$buildDir/outputs/apk/$exportEdition/$exportBuildType/$sourceFilename"
|
||||
|
||||
task copyAndRenameReleaseApk(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
|
||||
from "$buildDir/outputs/apk/release/android_release.apk"
|
||||
into getExportPath()
|
||||
rename "android_release.apk", getExportFilename()
|
||||
}
|
||||
|
||||
task copyAndRenameDebugAab(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
|
||||
from "$buildDir/outputs/bundle/debug/build-debug.aab"
|
||||
into getExportPath()
|
||||
rename "build-debug.aab", getExportFilename()
|
||||
}
|
||||
|
||||
task copyAndRenameDevAab(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
|
||||
from "$buildDir/outputs/bundle/dev/build-dev.aab"
|
||||
into getExportPath()
|
||||
rename "build-dev.aab", getExportFilename()
|
||||
}
|
||||
|
||||
task copyAndRenameReleaseAab(type: Copy) {
|
||||
// The 'doNotTrackState' is added to disable gradle's up-to-date checks for output files
|
||||
// and directories. Otherwise this check may cause permissions access failures on Windows
|
||||
// machines.
|
||||
doNotTrackState("No need for up-to-date checks for the copy-and-rename operation")
|
||||
|
||||
from "$buildDir/outputs/bundle/release/build-release.aab"
|
||||
into getExportPath()
|
||||
rename "build-release.aab", getExportFilename()
|
||||
from sourceFilepath
|
||||
into exportPath
|
||||
rename sourceFilename, exportFilename
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -12,7 +12,8 @@ ext.versions = [
|
|||
javaVersion : JavaVersion.VERSION_17,
|
||||
// Also update 'platform/android/detect.py#get_ndk_version()' when this is updated.
|
||||
ndkVersion : '23.2.8568313',
|
||||
splashscreenVersion: '1.0.1'
|
||||
splashscreenVersion: '1.0.1',
|
||||
openxrVendorsVersion: '3.1.2-stable'
|
||||
|
||||
]
|
||||
|
||||
|
|
@ -70,6 +71,11 @@ ext.getExportTargetSdkVersion = { ->
|
|||
}
|
||||
}
|
||||
|
||||
ext.getGodotRenderingMethod = { ->
|
||||
String renderingMethod = project.hasProperty("godot_rendering_method") ? project.property("godot_rendering_method") : ""
|
||||
return renderingMethod
|
||||
}
|
||||
|
||||
ext.getGodotEditorVersion = { ->
|
||||
String editorVersion = project.hasProperty("godot_editor_version") ? project.property("godot_editor_version") : ""
|
||||
if (editorVersion == null || editorVersion.isEmpty()) {
|
||||
|
|
@ -224,6 +230,30 @@ ext.getExportFilename = {
|
|||
return exportFilename
|
||||
}
|
||||
|
||||
ext.getExportEdition = {
|
||||
String exportEdition = project.hasProperty("export_edition") ? project.property("export_edition") : ""
|
||||
if (exportEdition == null || exportEdition.isEmpty()) {
|
||||
exportEdition = "standard"
|
||||
}
|
||||
return exportEdition
|
||||
}
|
||||
|
||||
ext.getExportBuildType = {
|
||||
String exportBuildType = project.hasProperty("export_build_type") ? project.property("export_build_type") : ""
|
||||
if (exportBuildType == null || exportBuildType.isEmpty()) {
|
||||
exportBuildType = "debug"
|
||||
}
|
||||
return exportBuildType
|
||||
}
|
||||
|
||||
ext.getExportFormat = {
|
||||
String exportFormat = project.hasProperty("export_format") ? project.property("export_format") : ""
|
||||
if (exportFormat == null || exportFormat.isEmpty()) {
|
||||
exportFormat = "apk"
|
||||
}
|
||||
return exportFormat
|
||||
}
|
||||
|
||||
/**
|
||||
* Parse the project properties for the 'plugins_maven_repos' property and return the list
|
||||
* of maven repos.
|
||||
|
|
@ -384,3 +414,8 @@ ext.shouldUseLegacyPackaging = { ->
|
|||
// Default behavior for minSdk >= 23
|
||||
return false
|
||||
}
|
||||
|
||||
ext.getAddonsDirectory = { ->
|
||||
String addonsDirectory = project.hasProperty("addons_directory") ? project.property("addons_directory") : ""
|
||||
return addonsDirectory
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,10 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
|
||||
<style name="GodotAppMainTheme" parent="@android:style/Theme.Black.NoTitleBar"/>
|
||||
<style name="GodotAppMainTheme" parent="@android:style/Theme.DeviceDefault.NoActionBar">
|
||||
<item name="android:windowDrawsSystemBarBackgrounds">false</item>
|
||||
<item name="android:windowSwipeToDismiss">false</item>
|
||||
</style>
|
||||
|
||||
<style name="GodotAppSplashTheme" parent="Theme.SplashScreen">
|
||||
<!-- Set the splash screen background, animated icon, and animation
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ pluginManagement {
|
|||
mavenCentral()
|
||||
gradlePluginPortal()
|
||||
maven { url "https://plugins.gradle.org/m2/" }
|
||||
maven { url "https://s01.oss.sonatype.org/content/repositories/snapshots/"}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -33,14 +33,29 @@ package com.godot.game;
|
|||
import org.godotengine.godot.GodotActivity;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
|
||||
import androidx.core.splashscreen.SplashScreen;
|
||||
|
||||
import com.godot.game.BuildConfig;
|
||||
|
||||
/**
|
||||
* Template activity for Godot Android builds.
|
||||
* Feel free to extend and modify this class for your custom logic.
|
||||
*/
|
||||
public class GodotApp extends GodotActivity {
|
||||
static {
|
||||
// .NET libraries.
|
||||
if (BuildConfig.FLAVOR.equals("mono")) {
|
||||
try {
|
||||
Log.v("GODOT", "Loading System.Security.Cryptography.Native.Android library");
|
||||
System.loadLibrary("System.Security.Cryptography.Native.Android");
|
||||
} catch (UnsatisfiedLinkError e) {
|
||||
Log.e("GODOT", "Unable to load System.Security.Cryptography.Native.Android library");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState) {
|
||||
SplashScreen.installSplashScreen(this);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue