Exemplo n.º 1
0
 def __init__(self, color, x, y):
     super().__init__(color, x, y)
     self.symbol = 'n'
     self.sprite = ps.piece_sprites(self)
     self.last_move = None
     self.points = 30 if self.color == 'w' else -30
     self.position_points = pp.get_position_points(self)
Exemplo n.º 2
0
 def evaluate_board(self):
     result = 0
     for row in self.board.board_arr:
         for piece in row:
             if piece is not None:
                 arr = pp.get_position_points(piece)
                 r = piece.points + arr[piece.y][piece.x]
                 result += r
     return result