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

Piece movement is incorrect #15

Open
Nixinova opened this issue Jul 23, 2021 · 1 comment · Fixed by #16
Open

Piece movement is incorrect #15

Nixinova opened this issue Jul 23, 2021 · 1 comment · Fixed by #16
Assignees
Labels
bug Something isn't working

Comments

@Nixinova
Copy link
Member

Nixinova commented Jul 23, 2021

Pawns are the only white pieces that can move:

image

findAllMoves('F1') = []

Also black piece movement validation is entirely incorrect.

@Nixinova Nixinova added the bug Something isn't working label Jul 23, 2021
@Nixinova Nixinova changed the title White non-pawns cannot move Piece movement is incorrect Jul 25, 2021
@Nixinova Nixinova self-assigned this Jul 25, 2021
Nixinova added a commit that referenced this issue Jul 25, 2021
Empty cells were being classified as black, leading to incorrect movement.

Fixes #15
@Nixinova Nixinova mentioned this issue Jul 25, 2021
Nixinova added a commit that referenced this issue Jul 26, 2021
* Update package-lock.json

* Document browser output

* Delete package-lock.json

Lockfile not needed

* Type cleanup

* Document `makeMove` param 3 `completeMove?`

* Minor cleanup

* Return undefined colour when cell is empty

Empty cells were being classified as black, leading to incorrect movement.

Fixes #15

* Restore package-lock.json

* Fix unchecked types

* Use nonnull assertion instead

Already checked for existence in the line above

* Improve board typing

* Add fen type

* Fix move list checking

* Version 0.4.3
@Nixinova Nixinova added the fixed This issue has been fixed label Jul 26, 2021
@Nixinova
Copy link
Member Author

Doesn't actually seem to be fixed even though the new tests passed...

@Nixinova Nixinova reopened this Jul 27, 2021
@Nixinova Nixinova removed the fixed This issue has been fixed label Jul 27, 2021
@Nixinova Nixinova mentioned this issue Jul 28, 2021
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
Development

Successfully merging a pull request may close this issue.

1 participant