mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 03:47:34 +00:00
Hearts: Make debugging AI suggestions easier
When building Hearts with HEARTS_DEBUG we highlight the card the AI would have picked. This makes comparing AI and human decisions easier.
This commit is contained in:
parent
2b2d992946
commit
4a8d8da46c
1 changed files with 5 additions and 0 deletions
|
@ -397,6 +397,11 @@ void Game::let_player_play_card()
|
|||
|
||||
if (player.is_human) {
|
||||
m_human_can_play = true;
|
||||
if constexpr (HEARTS_DEBUG) {
|
||||
auto card_index = pick_card(player);
|
||||
auto& card = player.hand[card_index];
|
||||
card->set_inverted(true);
|
||||
}
|
||||
update();
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue