Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Annotation symbols displayed on wrong square if castling #543

Closed
HaonRekcef opened this issue Feb 8, 2024 · 2 comments · Fixed by #567
Closed

Annotation symbols displayed on wrong square if castling #543

HaonRekcef opened this issue Feb 8, 2024 · 2 comments · Fixed by #567
Labels
bug Something isn't working

Comments

@HaonRekcef
Copy link
Contributor

What is the problem?

Annotation symbols displayed on wrong square if castling was the last move

Steps to reproduce the bug

  1. Find a game where castling is an inaccuracy, mistake or blunder
  2. Go to analysis

What did you expect to happen?

The shape should be displayed on the square the king moved to

What happened instead?

The shape was displayed on the square the rook moved from

Device Info

Pixel 6a

Operating System Version

Android 14

Additional information

Screenshot

Screenshot_20240207-233949

@HaonRekcef HaonRekcef added the bug Something isn't working label Feb 8, 2024
@okmsbun
Copy link
Contributor

okmsbun commented Feb 9, 2024

Yes I tested it and it seems wrong. It's not like Lischess.org. In fact, in different forms of castling, it is sometimes not shown at all. In the video below, when I do the same castling in different ways, 'annotation' is shown (incorrectly) in one and not shown at all in the other.

Here for that

annotations: currentNode.sanMove != null && annotation != null

than

const altCastles = {

and checking whether castling is done or not, it seems like it can be solved.

Screen_Recording_20240209_164821.mp4

@okmsbun
Copy link
Contributor

okmsbun commented Feb 9, 2024

When I leave the king to c8, the 'currentNode.nags' list ([]) here appears empty. This list should not be empty. The list should be the same as the list ([6]) that comes when the king is left on a8.

Game = https://lichess.org/407v1JxQ/black#29

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants