A chess library for Gleam

Add support for generating En Passant moves

+8
+8
src/starfish/internal/move.gleam
··· 86 86 Capture(from: position, to: new_position), 87 87 ..moves 88 88 ] 89 + Ok(board.Empty) if game.en_passant_square == Some(new_position) -> [ 90 + EnPassant(from: position, to: new_position), 91 + ..moves 92 + ] 89 93 Ok(board.Empty) | Ok(board.Occupied(_, _)) | Error(_) -> moves 90 94 } 91 95 ··· 93 97 case iv.get(game.board, new_position) { 94 98 Ok(board.Occupied(colour:, ..)) if colour != game.to_move -> [ 95 99 Capture(from: position, to: new_position), 100 + ..moves 101 + ] 102 + Ok(board.Empty) if game.en_passant_square == Some(new_position) -> [ 103 + EnPassant(from: position, to: new_position), 96 104 ..moves 97 105 ] 98 106 Ok(board.Empty) | Ok(board.Occupied(_, _)) | Error(_) -> moves