useKook
fun <A : Application> ApplicationBuilder<A>.useKook(usageBuilder: KookComponentUsageBuilder<A>.() -> Unit = {})
通过 KookComponentUsageBuilder 来同时配置使用 Kook 组件 和 Kook botManager。
usage:
simbotApplication(Foo) {
useKook()
// 或
useKook {
// 配置组件
component {
// ...
}
// 配置botManager
botManager {
// ...
}
}
}
Content copied to clipboard
相当于:
simbotApplication(Foo) {
install(KookComponent) {
// ...
}
install(KookBotManager) {
// ...
}
}
Content copied to clipboard