Skip to content

Commit c6df03d

Browse files
committed
fix: add game state 4 to completed
1 parent 69cd0d0 commit c6df03d

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/balatrollm/data_collection.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,9 @@ def calculate_stats(self) -> RunStats:
255255
stats.run_won = final_state["game"].get(
256256
"won", False
257257
) # TODO: check if "won" is the right key
258-
stats.completed = stats.run_won or final_state["state"] == "GAME_OVER"
258+
stats.completed = (
259+
stats.run_won or final_state["state"] == 4
260+
) # 4 is GAME_OVER game state
259261
stats.final_round = final_state["game"]["round"]
260262
stats.ante_reached = (
261263
max(1, (stats.final_round // 3) + 1) if stats.final_round > 0 else 1

0 commit comments

Comments
 (0)