mirror of
https://github.com/alexcrea/CustomAnvil.git
synced 2026-06-24 00:26:16 +02:00
Partially implemented eco enchant compatibility.
This commit is contained in:
parent
2e29e7f04e
commit
19806773a6
18 changed files with 143 additions and 35 deletions
|
|
@ -9,6 +9,7 @@ object DependencyManager {
|
|||
|
||||
lateinit var packetManager: PacketManager
|
||||
var enchantmentSquaredCompatibility: EnchantmentSquaredDependency? = null
|
||||
var ecoEnchantCompatibility: EcoEnchantDependency? = null
|
||||
|
||||
fun loadDependency(){
|
||||
val pluginManager = Bukkit.getPluginManager()
|
||||
|
|
@ -24,11 +25,17 @@ object DependencyManager {
|
|||
enchantmentSquaredCompatibility!!.disableAnvilListener()
|
||||
}
|
||||
|
||||
// EcoEnchants dependency
|
||||
if(pluginManager.isPluginEnabled("EcoEnchants")){
|
||||
ecoEnchantCompatibility = EcoEnchantDependency(pluginManager.getPlugin("EcoEnchants")!!)
|
||||
ecoEnchantCompatibility!!.disableAnvilListener()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
fun handleConfigChanges() {
|
||||
|
||||
enchantmentSquaredCompatibility?.registerPluginConfiguration()
|
||||
ecoEnchantCompatibility?.registerEnchantments()
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue