// set pole as visited private void _SetPoint(ChessCordinates poleCordinates) { if (poleCordinates.GetX() < 9 && poleCordinates.GetX() > 0 && poleCordinates.GetY() < 9 && poleCordinates.GetY() > 0) { this._chessMatrix[poleCordinates.GetX() - 1, poleCordinates.GetY() - 1] = true; } }
// helps to check if pole haven't been visited // return true if pole have been visited // return false if not private bool _CheckPoint(ChessCordinates poleCordinates) { if (poleCordinates.IsValid()) { return(this._chessMatrix[poleCordinates.GetX() - 1, poleCordinates.GetY() - 1]); } else { return(false); } }