wip points rules
This commit is contained in:
parent
7790c07dcc
commit
aff489f134
7 changed files with 62 additions and 10 deletions
|
|
@ -13,3 +13,4 @@ pretty_assertions = "1.4.0"
|
|||
renet = "0.0.13"
|
||||
store = { path = "../store" }
|
||||
bot = { path = "../bot" }
|
||||
itertools = "0.13.0"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
use itertools::Itertools;
|
||||
|
||||
use bot::Bot;
|
||||
use pretty_assertions::assert_eq;
|
||||
use store::{CheckerMove, DiceRoller, GameEvent, GameState, PlayerId, Stage, TurnStage};
|
||||
|
|
@ -186,7 +188,9 @@ impl App {
|
|||
if self.game.state.stage != Stage::PreGame {
|
||||
// display players points
|
||||
output += format!("\n\n{:<11} :: {:<5} :: {}", "Player", "holes", "points").as_str();
|
||||
for (player_id, player) in self.game.state.players.iter() {
|
||||
|
||||
for player_id in self.game.state.players.keys().sorted() {
|
||||
let player = &self.game.state.players[player_id];
|
||||
output += format!(
|
||||
"\n{}. {:<8} :: {:<5} :: {}",
|
||||
&player_id, &player.name, &player.holes, &player.points
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue