export every turn to save partial game

This commit is contained in:
Hayden Johnson 2026-02-19 21:13:31 -08:00
parent cdbe614e22
commit 6fe11226d0

View file

@ -40,8 +40,6 @@ main :: proc() {
}
}
// Create game
game: Game
if len(os.args) > 1 {
@ -63,9 +61,9 @@ main :: proc() {
for winner == -1 {
addScores(&game)
updatePhasesByScores(&game)
// fmt.println(game)
printGame(&game)
winner = checkWinner(&game)
exportGame(&game, "game.csv")
}
// Print winner and export game
@ -74,5 +72,4 @@ main :: proc() {
game.names[winner],
getScore(&game, winner)
)
exportGame(&game, "game.csv")
}