This commit is contained in:
2024-10-20 22:27:08 -05:00
parent f75553a0ad
commit 3593785421
27 changed files with 1020 additions and 1081 deletions

View File

@@ -39,7 +39,7 @@ public class BoardState
}
/// <summary>
/// Copy constructor.
/// Copy constructor. Creates a deep copy.
/// </summary>
public BoardState(BoardState other)
{
@@ -115,6 +115,7 @@ public class BoardState
var fromPiece = this[fromNotation]
?? throw new InvalidOperationException($"No piece exists at position {fromNotation}.");
if (isPromotionRequested &&
(IsWithinPromotionZone(to) || IsWithinPromotionZone(from)))
{