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

[バグ] Shogi.unmoveが駒取りをundoしない #143

Closed
ichibha opened this issue Jan 14, 2024 · 1 comment
Closed

[バグ] Shogi.unmoveが駒取りをundoしない #143

ichibha opened this issue Jan 14, 2024 · 1 comment

Comments

@ichibha
Copy link

ichibha commented Jan 14, 2024

"shogi.js": "^5.4.0"についてのバグ報告です。

問題:
全く同じ引数でShogiクラスのmoveとunmoveを連続して実行した場合には局面が変化しないことが期待されます。しかしながら、moveで駒取りが発生している場合、駒取りはundoされません。例えば、moveにより先手が後手の角を取り、それをunmoveした場合、先手の角は元の位置に戻る一方、後手の角は先手の駒台に残り続けます。

@ichibha
Copy link
Author

ichibha commented Jan 14, 2024

unmoveの仮引数captureにパラメタを与えていませんでした。

@ichibha ichibha closed this as completed Jan 14, 2024
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

1 participant