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

Is castling supported #3

Open
Bios-Marcel opened this issue Apr 23, 2021 · 6 comments
Open

Is castling supported #3

Bios-Marcel opened this issue Apr 23, 2021 · 6 comments

Comments

@Bios-Marcel
Copy link

Bios-Marcel commented Apr 23, 2021

I've tried doing castling and it doesn't seem to work.

I've tried the following:

0-0
0-0-0
00
000
o-o
o-o-o
oo
ooo

EDIT

While the readme answers my question, it didn't work nonetheless and I don't understand why. There was nothing inbetween my king and I see no reason why it wouldn't ahve worked. Is it possible to print the actual reason for being unable to move?

@tmountain
Copy link
Owner

Hi, castling should be fully supported. You can confirm this by testing with the following FEN (specified in your uchess config):

r3k2r/8/8/8/8/8/8/R3K2R w KQkq - 0 1

And then inputting either of the following moves: O-O or O-O-O.

Please note that all of the following conditions are required for a legal castle:

Your king and rook have not moved.
Your king is NOT in check.
Your king does not pass through check.
No pieces between the king and rook.

If you have a board position that meets these criteria, and castling is not working, please provide the FEN (type fen into uchess), and I will be happy to take a look.

@Bios-Marcel
Copy link
Author

Hm thanks for the reply. I am quite sure I met the conditions. In my infinite wisdom I forgot to take a picture or anything ^^'

@tmountain
Copy link
Owner

Ah, no worries, but I'm afraid I can't do much to diagnose it without a board position (at minimum). Move inputs are converted and processed by the notnil/chess package, which has a pretty robust test suite, but there's always a potential for things to get lost in translation. We can leave the issue open if you want to circle back with more data, or we can close it, and you can open a new issue if the problem happens again. I'm fine either way. Thanks!

@Bios-Marcel
Copy link
Author

Guess we can close this then. EIther way, is it possible to get more concrete errors instead of just Invalid?

@tmountain
Copy link
Owner

I'll leave it open and investigate the possibility of doing so. I'll circle back.

@Bios-Marcel
Copy link
Author

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants