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

Increase max number of moves in a study chapter #720

Closed
Olekaze opened this issue Aug 14, 2023 · 2 comments
Closed

Increase max number of moves in a study chapter #720

Olekaze opened this issue Aug 14, 2023 · 2 comments

Comments

@Olekaze
Copy link

Olekaze commented Aug 14, 2023

Currently you can't have a line longer than 400 moves in a chapter. However, chu games can occasionally go over 400 moves.

Also moves can't be numbered higher than 501. After 500 moves, if just flips between 500 and 501. If the move number in a FEN is higher than 500 and you plug in into a chapter, it reverts back to 500

@WandererXII
Copy link
Owner

I will fix the 500 number, the issue is here, ig. Thanks for reporting this: https://github.com/WandererXII/scalashogi/blob/main/src/main/scala/format/forsyth/Sfen.scala#L13

The 400 limit is necessary, because the implementation is recursive and it would blow the stack. I tried rewriting it to make it all tail recursive, but decided it's not worth it. Alternative is to increase stack size, but I don't know... These large studies would be slow anyway, so I think it's better to leave it as it is.

@WandererXII
Copy link
Owner

The 400 move limit is still in effect, because of the recursive implementation. But the move number can now go up to 9999.

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