def doMove(self, c, pos):
        self.movesDone += 1
        if not self.isLegal(c, pos):
            return False
        elif self._fiveRow(c, pos):
            self.winner = c
            self.b[pos] = 'x'
            return True
        else:
            self._setStone(c, pos)
            if self.movesDone == self.size[0] * self.size[1]:
                # DRAW
                self.winner = self.DRAW
            return True
the action is a (color, position) tuple, for the next stone to move.
dataset/ETHPy150Open pybrain/pybrain/pybrain/rl/environments/twoplayergames/gomoku.py/GomokuGame.doMove