forcebot_rs/src/custom.rs

24 lines
582 B
Rust
Raw Normal View History

2023-12-22 09:21:49 -05:00
/*
`modules` will :
- 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
mod experiments;
// [ ] 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-02-25 10:40:54 -05:00
experiments::init(mgr).await
}