Example #1
0
 private void SetPiece(PiecePosition position, Piece piece)
 {
     _pieces[position.Column - 'A', position.Line - 1] = piece;
 }
Example #2
0
 /// <summary>
 /// Rank is 1-8
 /// </summary>
 /// <param name="rank">1-8</param>
 public void SetSquare(File file, int rank, Piece p)
 {
     Squares[(int)file - 1, rank - 1].Piece = p;
 }
 /// <summary>
 /// Rank is 1-8
 /// </summary>
 /// <param name="rank">1-8</param>
 public void SetSquare(File file, int rank, Piece p)
 {
     LinearSquares[(int)file - 1 + (8 * (rank - 1))].Piece = p;
 }