diff --git a/build.gradle b/build.gradle index 846d56cc..216c8f53 100644 --- a/build.gradle +++ b/build.gradle @@ -58,12 +58,11 @@ allprojects { shadowJar { relocate('com.willfp.libreforge', 'com.willfp.talismans.libreforge') - relocate('redempt.crunch', 'com.willfp.talismans.libreforge.crunch') } dependencies { compileOnly 'com.willfp:eco:6.18.1' - implementation 'com.willfp:libreforge:2.18.1' + implementation 'com.willfp:libreforge:3.0.0' compileOnly 'org.jetbrains:annotations:23.0.0' diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/talismans/TalismansPlugin.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/talismans/TalismansPlugin.kt index ab4b79b6..32f1f1d1 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/talismans/TalismansPlugin.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/talismans/TalismansPlugin.kt @@ -1,19 +1,21 @@ package com.willfp.talismans -import com.willfp.eco.core.EcoPlugin import com.willfp.eco.core.command.impl.PluginCommand import com.willfp.eco.core.display.DisplayModule -import com.willfp.eco.core.integrations.IntegrationLoader import com.willfp.eco.core.items.CustomItem -import com.willfp.libreforge.LibReforge +import com.willfp.libreforge.LibReforgePlugin import com.willfp.talismans.command.CommandTalismans import com.willfp.talismans.config.TalismansYml import com.willfp.talismans.display.TalismanDisplay import com.willfp.talismans.talismans.Talismans -import com.willfp.talismans.talismans.util.* +import com.willfp.talismans.talismans.util.BlockPlaceListener +import com.willfp.talismans.talismans.util.DiscoverRecipeListener +import com.willfp.talismans.talismans.util.TalismanChecks +import com.willfp.talismans.talismans.util.TalismanCraftListener +import com.willfp.talismans.talismans.util.TalismanEnableListeners import org.bukkit.event.Listener -class TalismansPlugin : EcoPlugin(611, 9865, "&6", true) { +class TalismansPlugin : LibReforgePlugin(611, 9865, "&6") { val talismansYml = TalismansYml(this) /** @@ -21,21 +23,11 @@ class TalismansPlugin : EcoPlugin(611, 9865, "&6", true) { */ init { instance = this - LibReforge.init(this) - LibReforge.registerHolderProvider { TalismanChecks.getTalismansOnPlayer(it) } + registerHolderProvider { TalismanChecks.getTalismansOnPlayer(it) } } - override fun handleEnable() { - LibReforge.enable(this) - } - - override fun handleDisable() { - LibReforge.disable(this) - } - - override fun handleReload() { + override fun handleReloadAdditional() { logger.info("${Talismans.values().size} Talismans Loaded") - LibReforge.reload(this); CustomItem( this.namespacedKeyFactory.create("any_talisman"), { test -> TalismanChecks.getTalismanOnItem(test) != null }, @@ -43,10 +35,6 @@ class TalismansPlugin : EcoPlugin(611, 9865, "&6", true) { ).register() } - override fun loadIntegrationLoaders(): List { - return LibReforge.getIntegrationLoaders() - } - override fun loadPluginCommands(): List { return listOf( CommandTalismans(this) @@ -67,7 +55,7 @@ class TalismansPlugin : EcoPlugin(611, 9865, "&6", true) { } override fun getMinimumEcoVersion(): String { - return "6.17.0" + return "6.19.0" } companion object { diff --git a/gradle.properties b/gradle.properties index 8886f965..f8040e3a 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,2 +1,2 @@ -version = 5.7.3 +version = 5.8.0 plugin-name = Talismans \ No newline at end of file