Exemplo n.º 1
0
        public void UndoMovement(Position origin, Position destiny, Chessman caughtChessman)
        {
            Chessman piece = Board.RemoveChessPiece(destiny);

            piece.DecreasePieceMoves();
            if (caughtChessman != null)
            {
                Board.PutChessPiece(caughtChessman, destiny);
                CapturedChessman.Remove(caughtChessman);
            }
            Board.PutChessPiece(piece, origin);
        }