Add copy constructor to the setCapturedPiece method.