fix: count ones as bdr only if the second copy is lost

This commit is contained in:
Maximilian Keßler 2023-12-31 20:23:00 +01:00
parent 542d40282a
commit ea723bdaff
Signed by: max
GPG key ID: BCC5A619923C0BA5

View file

@ -52,7 +52,7 @@ def analyze_replay(instance: hanab_game.HanabiInstance, actions: List[hanab_game
if card == game.deck[-1]: if card == game.deck[-1]:
outcomes.add(GameOutcome.bottom_deck) outcomes.add(GameOutcome.bottom_deck)
else: else:
if game.deck[game.progress:].count(card) == 2: if game.deck[game.progress:].count(card) == 1:
bdrs.append((card, game.draw_pile_size)) bdrs.append((card, game.draw_pile_size))
if card == game.deck[-1]: if card == game.deck[-1]:
outcomes.add(GameOutcome.bottom_deck) outcomes.add(GameOutcome.bottom_deck)