From bcdd131be7dffc2bbf820340c4baac9f4df10508 Mon Sep 17 00:00:00 2001 From: Anna Wiggins Date: Fri, 13 Apr 2012 01:41:33 -0400 Subject: [PATCH] Fix color changing between moves --- lib/goban.py | 1 + pygo.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/goban.py b/lib/goban.py index 66dbcea..6b96a09 100644 --- a/lib/goban.py +++ b/lib/goban.py @@ -84,6 +84,7 @@ class Goban: if Goban.libboard.is_legal(realpos, color): Goban.libboard.play_move(realpos, color) + self.to_move = self.OTHER_COLOR(self.to_move) return True else: return False diff --git a/pygo.py b/pygo.py index ff8c35e..b8d3ec4 100755 --- a/pygo.py +++ b/pygo.py @@ -112,7 +112,7 @@ def main(): if x <= board_size: if event.button == 1: - goban.play_move((col, row)) + goban.play_move((col,row)) board = goban.draw_board(board_size, img_res)