-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBoard.h
More file actions
51 lines (43 loc) · 1.11 KB
/
Board.h
File metadata and controls
51 lines (43 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
//
// Board.h
// BCAI
//
// Created by Max Botviniev on 20.10.15.
// Copyright (c) 2015 Max Botviniev. All rights reserved.
//
#ifndef __BCAI__Board__
#define __BCAI__Board__
#include <vector>
//----------------
#include "Tile.hpp"
//----------------
#include "Piece.h"
//----------------
#include "King.h"
#include "Queen.h"
#include "Rook.h"
#include "Officer.h"
#include "Steed.h"
#include "Pawn.h"
//-------------
//DEBUG
#include <iostream>
namespace BCAI {
class Board
{
public:
Tile * tiles_table_v[8][8];
std::vector<Piece> pieces;
//------------------------
Board( const char * input_info_p );
Piece & Parse( const char str_piece_v[4] );
Piece & GetPiece( IndexPair adress );
int DesiredAxe( IndexPair & from, IndexPair & to );
bool AllowedMove( const char * move_p );
//bool AllowedOneStep(IndexPair & step, IndexPair & to);
bool AllowedMoveAxe(IndexPair & from, IndexPair & to);
bool AllowedMovePawn(IndexPair & from, IndexPair & to);
bool AllowedMoveKing(IndexPair & from, IndexPair & to);
};
}
#endif /* defined(__BCAI__Board__) */