public Board(Board other) : this(other._numPlayers) { accessible = (int[, ])other.accessible.Clone(); for (int i = 0; i < _numPlayers; i++) { playerStatus[i] = new PlayerInfo(other.playerStatus[i]); } for (int i = 0; i < BOARD_SIZE; i++) { for (int j = 0; j < BOARD_SIZE; j++) { if (i < BOARD_SIZE - 1 && j < BOARD_SIZE - 1) { wallPegStatus[i, j] = new WallPeg(other.wallPegStatus[i, j]); } boardStatus[i, j] = new gameSquareInfo(other.boardStatus[i, j]); } } }
public WallPeg(WallPeg other) { x = other.x; y = other.y; isOpen = other.isOpen; }