summaryrefslogtreecommitdiffstats
path: root/grid.cpp
blob: b06978266dd1085e5b6a45d64e390aedeaa418f4 (plain)
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
52
53
54
55
56
57
58
/*
 * grid.cpp
 *
 *
 */

#include "grid.h"

Grid::Grid(void) : rows(0), cols(0), numOfMoves(0), lastMoved(0), lastMoveDir(0), board(NULL)
{
}

#if 0
Grid::Grid(const Grid &grid) : rows(grid.rows), cols(grid.cols), numOfMoves(grid.numOfMoves),
                               lastMoved(grid.lastMoved), lastMoveDir(grid.lastMoveDir), board(new string(*grid.board))
{

}
#endif

int *Grid::getRows(void)
{
	return &rows;
}

int *Grid::getCols(void)
{
	return &cols;
}

int *Grid::getNumOfMoves(void)
{
	return &numOfMoves;
}

vector<Piece> *Grid::getPieces(void)
{
    return &pieces;
}

void Grid::setRows(int n)
{
	rows = n;
}

void Grid::setCols(int n)
{
	cols = n;
}

void Grid::addMove(string move)
{
    moves.push_back(move);
}

void Grid::markPiecesPos(void)
{
}