2023-12-22 09:21:49 -05:00
|
|
|
/*
|
2024-03-23 13:32:22 -04:00
|
|
|
`custom` will :
|
2023-12-22 09:21:49 -05:00
|
|
|
- be a starting refrence point for the bot instance to pull module definitions for
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
2024-03-02 09:44:09 -05:00
|
|
|
use std::sync::Arc;
|
2023-12-22 09:21:49 -05:00
|
|
|
|
|
|
|
pub use crate::core::botinstance::BotInstance;
|
2024-03-02 09:44:09 -05:00
|
|
|
pub use crate::core::botmodules::ModulesManager;
|
2023-12-22 09:21:49 -05:00
|
|
|
|
|
|
|
// [ ] Load submodules
|
|
|
|
|
2024-03-23 13:32:22 -04:00
|
|
|
// mod experiments;
|
|
|
|
mod experimental;
|
2024-03-28 17:50:28 -04:00
|
|
|
mod thisguy;
|
2023-12-22 09:21:49 -05:00
|
|
|
|
|
|
|
// [ ] init() function that accepts bot instance - this is passed to init() on submodules
|
|
|
|
|
2024-02-25 10:40:54 -05:00
|
|
|
pub async fn init(mgr: Arc<ModulesManager>) {
|
2023-12-22 09:21:49 -05:00
|
|
|
// Modules initializer loads modules into the bot
|
|
|
|
// this is achieved by calling submodules that also have fn init() defined
|
|
|
|
|
2024-03-23 13:32:22 -04:00
|
|
|
// experiments::init(mgr).await
|
2024-03-28 17:50:28 -04:00
|
|
|
experimental::init(mgr.clone()).await;
|
|
|
|
thisguy::init(&mgr).await;
|
2024-02-25 10:40:54 -05:00
|
|
|
}
|