diff --git a/src/game.rs b/src/game.rs index b190bcc..1b219b6 100644 --- a/src/game.rs +++ b/src/game.rs @@ -65,6 +65,7 @@ impl Game { /// Once the two player has been registered, the game may start fn query_boats_disposition(&mut self) { + log::debug!("Query boats disposition"); assert_eq!(self.status, GameStatus::Created); self.status = GameStatus::WaitingForBoatsDisposition; self.players[0].query_boats_layout(&self.rules); @@ -74,6 +75,7 @@ impl Game { /// Start fires exchange fn start_fire_exchanges(&mut self) { self.status = GameStatus::Started; + log::debug!("Start fire exchanges"); } } @@ -113,6 +115,7 @@ impl Handler for Game { fn handle(&mut self, msg: SetBoatsLayout, _ctx: &mut Self::Context) -> Self::Result { assert_eq!(self.status, GameStatus::WaitingForBoatsDisposition); let player_index = self.player_id_by_uuid(msg.0); + log::debug!("Got boat disposition for player {}", player_index); match player_index { 0 => self.map_0 = Some(GameMap::new(self.rules.clone(), msg.1)), 1 => self.map_1 = Some(GameMap::new(self.rules.clone(), msg.1)), diff --git a/src/human_player_ws.rs b/src/human_player_ws.rs index 179c852..7298266 100644 --- a/src/human_player_ws.rs +++ b/src/human_player_ws.rs @@ -59,6 +59,7 @@ impl Actor for HumanPlayerWS { // Start game, according to appropriate start mode match &self.start_mode { StartMode::Bot(rules) => { + log::debug!("Start play with a bot"); let game = Game::new(rules.clone()).start(); match rules.bot_type {