Yep
This commit is contained in:
@@ -91,6 +91,11 @@ public sealed class ShogiBoard(BoardState initialState)
|
||||
|
||||
public MoveResult Move(WhichPiece pieceInHand, string to)
|
||||
{
|
||||
if (BoardState.IsCheckmate)
|
||||
{
|
||||
return new MoveResult(false, "The game is over. A winner has been decided.");
|
||||
}
|
||||
|
||||
var index = BoardState.ActivePlayerHand.FindIndex(p => p.WhichPiece == pieceInHand);
|
||||
if (index == -1)
|
||||
{
|
||||
@@ -250,7 +255,8 @@ public sealed class ShogiBoard(BoardState initialState)
|
||||
list.Add(position);
|
||||
position += path.Step;
|
||||
}
|
||||
} else if (position.IsInsideBoardBoundary())
|
||||
}
|
||||
else if (position.IsInsideBoardBoundary())
|
||||
{
|
||||
list.Add(position);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user