Started to work on king threats
This commit is contained in:
@@ -64,8 +64,9 @@ public struct Fen: CustomStringConvertible {
|
||||
}
|
||||
|
||||
internal mutating func set(
|
||||
from board: Board.Grid, castling ca: CastlingAvailibility,
|
||||
enPassant: String
|
||||
from board: Board.Grid, activeColor: Color,
|
||||
castling ca: CastlingAvailibility,
|
||||
enPassant: String, halfMoveClock hmc: UInt8, fullMoveClock fmc: UInt8
|
||||
) {
|
||||
#warning(
|
||||
"Determine active color, halfMoveClock, fullMoveClock based on history SAN later passed in arguments"
|
||||
@@ -95,7 +96,8 @@ public struct Fen: CustomStringConvertible {
|
||||
rankNr += 1
|
||||
}
|
||||
|
||||
value = placement + " w " + ca.rawValue + " " + enPassant + " 0 " + "1"
|
||||
value =
|
||||
"\(placement) \(activeColor) \(ca.rawValue) \(enPassant) \(halfMoveClock) \(fullMoveClock)"
|
||||
}
|
||||
|
||||
public enum FenError: Error {
|
||||
|
||||
Reference in New Issue
Block a user