Chessboard.h 536 B

12345678910111213141516171819202122232425262728
  1. #ifndef _CHESSBOARD_H
  2. #define _CHESSBOARD_H
  3. #include <vector>
  4. #include "Figure.h"
  5. #include "Position.h"
  6. #include "Cell.h"
  7. #include <utility>
  8. #include <iostream>
  9. class Chessboard
  10. {
  11. private:
  12. Cell** board;
  13. vector<std::pair<Position, Position>> moves;
  14. vector<Position> get_possible_moves(Figure* fig);
  15. Cell get_cell(Position pos);
  16. public:
  17. Chessboard(vector<Figure*>);
  18. void create_move(Position pos1, Position pos2);
  19. friend std::ostream& operator <<(std::ostream& out, Chessboard& chess);
  20. };
  21. #endif