1.3 | Multiversion (1.21.4-26.1.2)

This commit is contained in:
Patrick
2026-08-16 21:01:50 +02:00
parent 55a82a1cd1
commit b1de9b80a0
11 changed files with 245 additions and 30 deletions
+13 -10
View File
@@ -4,7 +4,7 @@ plugins {
}
group = 'de.winniepat'
version = '1.2'
version = '1.3'
repositories {
mavenCentral()
@@ -12,8 +12,12 @@ repositories {
maven { url = 'https://jitpack.io' }
}
def mcVersion = project.findProperty('mcVersion') ?: '1.21.4-R0.1-SNAPSHOT'
def deployDir = project.findProperty('deployDir') ?: 'C:/Users/winnie/Documents/lunaris/server/plugins'
def minJavaVersion = 21
dependencies {
compileOnly('io.papermc.paper:paper-api:1.21.4-R0.1-SNAPSHOT')
compileOnly("io.papermc.paper:paper-api:${mcVersion}")
compileOnly('com.github.MilkBowl:VaultAPI:1.7') {
exclude group: 'org.bukkit', module: 'bukkit'
@@ -26,21 +30,20 @@ tasks {
}
}
def targetJavaVersion = 21
java {
def javaVersion = JavaVersion.toVersion(targetJavaVersion)
def javaVersion = JavaVersion.toVersion(minJavaVersion)
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
if (JavaVersion.current() < javaVersion) {
toolchain.languageVersion = JavaLanguageVersion.of(targetJavaVersion)
toolchain.languageVersion = JavaLanguageVersion.of(minJavaVersion)
}
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
if (targetJavaVersion >= 10 || JavaVersion.current().isJava10Compatible()) {
options.release.set(targetJavaVersion)
if (minJavaVersion >= 10 || JavaVersion.current().isJava10Compatible()) {
options.release.set(minJavaVersion)
}
}
@@ -55,7 +58,7 @@ processResources {
build.doLast {
copy {
from("$buildDir/libs/GamblingPlugin-1.2.jar")
into("C:/Users/winnie/Documents/lunaris/server/plugins")
from("$buildDir/libs/${rootProject.name}-${version}.jar")
into(deployDir)
}
}
}