added small comment

This commit is contained in:
Karma Riuk 2025-02-02 21:22:38 +01:00
parent 8a3a92f80f
commit f5292fa6d7

View File

@ -29,6 +29,7 @@ std::vector<Move> pawn_moves(const Board& b, const Coords xy) {
}
}
// -- Promotion
bool is_on_starting_rank =
my_colour == Colour::White ? xy.y == 1 : xy.y == 6;
int max_dy = is_on_starting_rank ? 3 : 2;