Update build configurations and add villager messaging functionality

This commit updates the version of the shadow plugin and the Java language version in the build configuration. Modifications have been made in the shadowJar configuration. The main feature in this commit is the introduction of a messaging system for villagers. This includes the necessary methods and fields in the existing villager classes and the addition of a new VillagerMessagesConfig class. Messages can now be added via config and each villager type can potentially return a random message when interacted with. A sound effect has also been added to correlate with the villager type. The WorthConfig class has been additionally refined to handle invalid material cases.
This commit is contained in:
auto committed 2024-07-09 18:32:50 +02:00
1 parent cbae508f04
commit 9f18b41925
8 files changed
+148 -13

No files matched your search

+9 -11
View File
@@ -2,7 +2,7 @@ import com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocatio
plugins {
id("java")
id("com.github.johnrengelman.shadow") version "7.1.0"
id("com.github.johnrengelman.shadow") version "7.1.1"
id("maven-publish")
}
@@ -14,7 +14,7 @@ apply<JavaLibraryPlugin>()
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
languageVersion.set(JavaLanguageVersion.of(21))
}
}
@@ -44,24 +44,22 @@ tasks {
}
shadowJar {
dependsOn(getByName("relocateJars") as ConfigureShadowRelocation)
archiveFileName.set("${project.name}-${project.version}.jar")
minimize()
configurations = listOf(project.configurations.shadow.get())
archiveFileName.set("${rootProject.name}.jar")
manifest {
attributes("Main-Class" to "VillagerUI")
}
}
build {
dependsOn(shadowJar)
}
create<ConfigureShadowRelocation>("relocateJars") {
target = shadowJar.get()
prefix = "${project.name}.lib"
}
}
dependencies {
compileOnly("com.alttd:Galaxy-API:1.19-R0.1-SNAPSHOT")
compileOnly("com.alttd:Galaxy-API:1.21-R0.1-SNAPSHOT") {
isChanging = true
}
compileOnly("com.github.milkbowl:VaultAPI:1.7") {
exclude("org.bukkit","bukkit")
}