register Suspending Listener
fun <ERROR CLASS>.registerSuspendingListener(plugin: <ERROR CLASS>, listener: <ERROR CLASS>)
Content copied to clipboard
Registers an event listener with suspending functions. Does exactly the same thing as PluginManager.registerListener but makes suspension functions possible. Example:
class MyListener : Listener{ @EventHandler suspend fun onPostLoginEvent(event: PostLoginEvent) {
}
}
Parameters
listener
BungeeCord Listener.
plugin
BungeeCord Plugin.