hrushikeshrv / chessengine

A WIP chess engine written in Python with no dependencies
https://chessengine.readthedocs.io/en/latest/index.html
MIT License
12 stars 13 forks source link

Computer's last move not written out anymore #33

Closed zzril closed 2 years ago

zzril commented 2 years ago

While fixing the scrolling issue (#25 ), I think we may have messed up the part where the computer's move is printed out in text.
See bitboard.py, line 666:

                    print(
                        f"Board moves from {pos_to_coords[log2(best_move[0])]} to {pos_to_coords[log2(best_move[1])]}"
                    )

This Board moves from... line is never actually seen on stdout, probably because it's being cleared too early.

Example output on my terminal:
Terminal output after 2 moves from each side, with no information on black's last move (2...d5) being printed
(As you can see, the line from the code snippet above cannot be seen on my terminal.)