Removed need for local.properties file

This commit is contained in:
Anuken
2020-03-28 17:03:52 -04:00
parent 73f7681f59
commit 65bf97bc03
3 changed files with 12 additions and 14 deletions

View File

@ -29,12 +29,10 @@ dependencies{
implementation arcModule("backends:backend-android")
implementation 'com.jakewharton.android.repackaged:dalvik-dx:9.0.0_r3'
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi"
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-armeabi-v7a"
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-arm64-v8a"
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-x86"
natives "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-x86_64"
natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-armeabi"
natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-armeabi-v7a"
natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-arm64-v8a"
natives "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-x86"
@ -119,7 +117,6 @@ android{
// the natives configuration, and extracts them to the proper libs/ folders
// so they get packed with the APK.
task copyAndroidNatives(){
file("libs/armeabi/").mkdirs()
file("libs/armeabi-v7a/").mkdirs()
file("libs/arm64-v8a/").mkdirs()
file("libs/x86_64/").mkdirs()
@ -129,7 +126,6 @@ task copyAndroidNatives(){
def outputDir = null
if(jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a")
if(jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a")
if(jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi")
if(jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64")
if(jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86")
if(outputDir != null){

View File

@ -217,8 +217,8 @@ public class PlanetDialog extends FloatingDialog{
draw(sec, shadowColor, -0.001f);
}
if(sec.hostility >= 0f){
drawSelection(sec, Color.scarlet, 0.1f * sec.hostility);
if(sec.hostility >= 0.02f){
drawSelection(sec, Color.scarlet, 0.11f * sec.hostility);
}
}

View File

@ -7,16 +7,18 @@ def use = { ... names ->
}
}
def properties = new Properties()
def hasSdk = System.getenv("ANDROID_HOME") != null
if(new File(settingsDir, 'local.properties').exists() && System.getenv("JITPACK") != "true"){
properties.load(new File(settingsDir, 'local.properties').newDataInputStream())
if(new File(settingsDir, 'local.properties').exists()){
def properties = new Properties()
properties.load(new File(settingsDir, 'local.properties').newDataInputStream())
if(properties.containsKey("sdk.dir")) hasSdk = true
}
if(properties.containsKey("sdk.dir")){
include 'android'
}else{
println("No android SDK dir found Not loading Android module.")
}
if(System.getenv("JITPACK") == "true") hasSdk = false
if(hasSdk){
include 'android'
}else{
println("No local.properties found. Not loading Android module.")
}