39 lines
1.5 KiB
Groovy
39 lines
1.5 KiB
Groovy
apply plugin: "java"
|
|
|
|
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
|
|
sourceCompatibility = targetCompatibility = appJavaCompatibility
|
|
|
|
ext.mainClass = "com.shatteredpixel.shatteredpixeldungeon.desktop.DesktopLauncher"
|
|
sourceSets.main.resources.srcDirs = [new File(project(':core').projectDir, "/src/main/assets"),
|
|
new File(project(':desktop').projectDir,"/src/main/assets")]
|
|
|
|
task runDebug(dependsOn: classes, type: JavaExec) {
|
|
classpath = sourceSets.main.runtimeClasspath
|
|
ignoreExitValue = true
|
|
|
|
main = mainClass
|
|
systemProperty 'Specification-Title', appName
|
|
systemProperty 'Specification-Version', appVersionName + "-INDEV"
|
|
systemProperty 'Implementation-Version', appVersionCode
|
|
}
|
|
|
|
task releaseJAR(dependsOn: classes, type: Jar) {
|
|
from sourceSets.main.output
|
|
from { configurations.runtimeClasspath.findAll { it.name.endsWith('jar') }.collect { zipTree(it) } }
|
|
|
|
manifest {
|
|
attributes 'Main-Class': mainClass
|
|
attributes 'Specification-Title': appName
|
|
attributes 'Specification-Version': appVersionName
|
|
attributes 'Implementation-Version': appVersionCode
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
implementation project(':core')
|
|
|
|
implementation "com.badlogicgames.gdx:gdx-freetype:$gdxVersion"
|
|
implementation "com.badlogicgames.gdx:gdx-backend-lwjgl3:$gdxVersion"
|
|
implementation "com.badlogicgames.gdx:gdx-platform:$gdxVersion:natives-desktop"
|
|
implementation "com.badlogicgames.gdx:gdx-freetype-platform:$gdxVersion:natives-desktop"
|
|
} |