コード例 #1
0
ファイル: Square.cs プロジェクト: smorkeks/chessForms
 // Set the input square to an exact copy of this square.
 public void Copy(Square oldSquare)
 {
     posX       = oldSquare.posX;
     posY       = oldSquare.posY;
     whiteCover = oldSquare.whiteCover;
     blackCover = oldSquare.blackCover;
     if (oldSquare.piece != null)
     {
         piece = oldSquare.piece.getCopyPiece();
         piece.Copy(oldSquare.piece);
     }
     else
     {
         piece = null;
     }
 }
コード例 #2
0
ファイル: Square.cs プロジェクト: smorkeks/chessForms
 // Set the input square to an exact copy of this square.
 public void Copy(Square oldSquare)
 {
     posX = oldSquare.posX;
     posY = oldSquare.posY;
     whiteCover = oldSquare.whiteCover;
     blackCover = oldSquare.blackCover;
     if (oldSquare.piece != null)
     {
         piece = oldSquare.piece.getCopyPiece();
         piece.Copy(oldSquare.piece);
     }
     else
     {
         piece = null;
     }
 }