pub mod core; pub mod modules; use std::process::Output; use crate::core::botinstance::ArcBox; use crate::core::botinstance::BotInstance; use tokio::sync::RwLock; use std::sync::Arc; pub type BotAR = Arc>; #[tokio::main] pub async fn main() { let bot = BotInstance::init().await; let a = Arc::clone(&bot.botmodules.botactions); let a = a.read().await; // let a = *a; for (_,acts) in &*a { for act in acts { match act { crate::core::botmodules::BotAction::C(b) => println!("bot actiions: {}",b.command), crate::core::botmodules::BotAction::L(l) => println!("bot actiions: {}",l.name), _ => println!("Not a valid match??"), } } }; println!("Starting runner.."); bot.runner().await; println!("ERROR : EXIT Game loop"); }