Test plugin dependencies and casting the existing instance.

This commit is contained in:
Logan Gorence
2021-12-21 09:07:10 +00:00
parent aed37ae013
commit e303f6f937
3 changed files with 25 additions and 3 deletions

View File

@ -1,3 +1,5 @@
dependencies {
implementation("net.dv8tion:JDA:5.0.0-alpha.2")
compileOnly(project(":foundation-core"))
}

View File

@ -1,9 +1,13 @@
package cloud.kubelet.foundation.bifrost
import cloud.kubelet.foundation.core.FoundationCorePlugin
import org.bukkit.plugin.java.JavaPlugin
class FoundationBifrostPlugin : JavaPlugin() {
override fun onEnable() {
slF4JLogger.info("Enabling!")
val foundation = server.pluginManager.getPlugin("Foundation") as FoundationCorePlugin
slF4JLogger.info("Plugin data path: ${foundation.pluginDataPath}")
}
}