chess_logic v0.2.2 ChessLogic.Position
Documentation for Position.
This is the main interface to chessfold functions. It is used mainly by Game.
Link to this section Summary
Functions
Returns a list of all available moves, represented as string
Returns the tally of the position
Returns a list of pieces with square from a given position
Transforms a move to a short algebraic notation. eg. “g1f3” -> “Nf3”
Returns a new position from a fen string. Returns default position if fen is not given
Play a move. a move looks like “e2e4”
Transforms a short algebraic notation to a move. eg. “Nf3” -> “g1f3”
Link to this section Types
Link to this section Functions
Returns a list of all available moves, represented as string.
Returns the tally of the position.
Returns a list of pieces with square from a given position.
Transforms a move to a short algebraic notation. eg. “g1f3” -> “Nf3”.
Returns a new position from a fen string. Returns default position if fen is not given.
Play a move. a move looks like “e2e4”.
Transforms a short algebraic notation to a move. eg. “Nf3” -> “g1f3”.