wip debug get_valid_actions for black
This commit is contained in:
parent
65180d8164
commit
817dbd77a7
10 changed files with 200 additions and 41 deletions
|
|
@ -22,7 +22,7 @@ impl TricTrac {
|
|||
game_state.init_player("player2");
|
||||
|
||||
// Commencer la partie avec le joueur 1
|
||||
game_state.consume(&GameEvent::BeginGame { goes_first: 1 });
|
||||
let _ = game_state.consume(&GameEvent::BeginGame { goes_first: 1 });
|
||||
|
||||
TricTrac { game_state }
|
||||
}
|
||||
|
|
@ -69,7 +69,8 @@ impl TricTrac {
|
|||
}
|
||||
|
||||
let dice = Dice { values: dices };
|
||||
self.game_state
|
||||
let _ = self
|
||||
.game_state
|
||||
.consume(&GameEvent::RollResult { player_id, dice });
|
||||
Ok(())
|
||||
}
|
||||
|
|
@ -86,7 +87,7 @@ impl TricTrac {
|
|||
.map(|e| if needs_mirror { e.get_mirror(false) } else { e })
|
||||
}) {
|
||||
if self.game_state.validate(&event) {
|
||||
self.game_state.consume(&event);
|
||||
let _ = self.game_state.consume(&event);
|
||||
return Ok(());
|
||||
} else {
|
||||
return Err(pyo3::exceptions::PyRuntimeError::new_err(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue