diff --git a/build.gradle.kts b/build.gradle.kts index 27f432a..1a57adc 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,8 +1,8 @@ plugins { + id("com.gradleup.shadow") version "8.3.2" // Import shadow API. java // Tell gradle this is a java project. - id("io.github.goooler.shadow") version "8.1.8" // Import shadow plugin for dependency shading. eclipse // Import eclipse plugin for IDE integration. - kotlin("jvm") version "1.9.23" // Import kotlin jvm plugin for kotlin/java integration. + kotlin("jvm") version "2.0.20" // Import kotlin jvm plugin for kotlin/java integration. } java { @@ -29,7 +29,7 @@ tasks.named("processResources") { repositories { mavenCentral() - + gradlePluginPortal() maven { url = uri("https://repo.purpurmc.org/snapshots") // Import the PurpurMC Maven Repository. } @@ -46,7 +46,7 @@ dependencies { compileOnly("io.github.miniplaceholders:miniplaceholders-api:2.2.3") // Import MiniPlaceholders API. compileOnly("com.github.Realizedd.Duels:duels-api:3.5.1") // Build the Duels API. - // implementation(project(":libs:Utilities-OG")) + implementation(project(":libs:Utilities-OG")) implementation(project(":libs:GxUI-OG")) } @@ -56,39 +56,36 @@ tasks.withType().configureEach { // Ensure reproducible bui } tasks.shadowJar { + archiveClassifier.set("") // Use empty string instead of null + from("LICENSE") { + into("/") + } exclude("io.github.miniplaceholders.*") // Exclude the MiniPlaceholders package from being shadowed. minimize() } -tasks.jar { +tasks.build { dependsOn(tasks.shadowJar) - archiveClassifier.set("part") -} - -tasks.shadowJar { - archiveClassifier.set("") // Use empty string instead of null - from("LICENSE") { // Copies license file. - into("/") // Sets destination for license file within the completed .jar. - } } tasks.jar { - dependsOn("shadowJar") // Ensures shadowJar gets run. + archiveClassifier.set("part") } tasks.withType().configureEach { options.compilerArgs.add("-parameters") - options.encoding = "UTF-8" // Use UTF-8 encoding universally. + options.compilerArgs.add("-Xlint:deprecation") // Triggers deprecation warning messages. + options.encoding = "UTF-8" options.isFork = true } kotlin { - jvmToolchain(17) // Declare kotlin jvm toolchain version. + jvmToolchain(17) } java { toolchain { - languageVersion = JavaLanguageVersion.of(17) // Declare JDK version. - vendor = JvmVendorSpec.GRAAL_VM // Declare JDK distribution. + languageVersion = JavaLanguageVersion.of(17) + vendor = JvmVendorSpec.GRAAL_VM } } \ No newline at end of file diff --git a/libs/GxUI-OG b/libs/GxUI-OG index ec6120a..b006ff1 160000 --- a/libs/GxUI-OG +++ b/libs/GxUI-OG @@ -1 +1 @@ -Subproject commit ec6120a73df4c3529d88f583ffaa6beedccc069d +Subproject commit b006ff1070ae5ba06d71e30a79c641707c9e5d98 diff --git a/libs/Utilities-OG b/libs/Utilities-OG index a204510..f973ab6 160000 --- a/libs/Utilities-OG +++ b/libs/Utilities-OG @@ -1 +1 @@ -Subproject commit a20451051616f9d1e35826919f58fcaf4a9aa5cf +Subproject commit f973ab638b7815bdb609333348f0e3df36a1c203 diff --git a/settings.gradle.kts b/settings.gradle.kts index 38f8a8c..3123169 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -6,5 +6,5 @@ exec { commandLine("sh", "bootstrap.sh") } -// include("libs:Utilities-OG") -include("libs:GxUI-OG") \ No newline at end of file +include("libs:Utilities-OG") +include("libs:GxUI-OG") diff --git a/src/main/java/plugin/Listeners.java b/src/main/java/plugin/Listeners.java index 764d7b8..37459ab 100644 --- a/src/main/java/plugin/Listeners.java +++ b/src/main/java/plugin/Listeners.java @@ -11,7 +11,7 @@ import org.bukkit.event.Listener; import org.bukkit.event.player.PlayerGameModeChangeEvent; import me.realized.duels.api.Duels; -import net.kyori.adventure.text.minimessage.MiniMessage; +import net.trueog.utilitiesog.UtilitiesOG; public class Listeners implements Listener { @@ -42,7 +42,7 @@ public class Listeners implements Listener { if(player.getGameMode() == GameMode.SURVIVAL) { // Inform the player that they will stop spectating the match. - player.sendMessage(MiniMessage.miniMessage().deserialize("[TrueOG] Out of bounds! Your Duel spectating session has ended.")); + UtilitiesOG.trueogMessage(player, "[TrueOG] Out of bounds! Your Duel spectating session has ended."); // Stop the player from spectating the match. api.getSpectateManager().stopSpectating(player);