-
Notifications
You must be signed in to change notification settings - Fork 3
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
Rollback of chain should not roll back start of move promotion #79
Comments
This is even stranger. When your turn starts and you get to promote at the start, then the button to rollback is available. It should not be available and it correctly does nothing. After you have promoted, the button could arguably be available (It is your time after all so why not do a different decision) - But it is not available. Now after you lift a piece, the option becomes available and fully rolls back your move including the promotion at the start. |
I tried to fix this by pushing the "Required Action" into the current match state. And then I wanted to derive it from that. That still doesn't allow me do differentiate between "Your turn started, Lift a piece" and "You just promoted and now get to lift". Only in the second position is a rollback allowed. It seems like Rollback behaves like a "Legal Action" so I should try to derive it in client JavaScript instead. |
Elm Side: Rust (Wasm) Side: |
Happy with the state I have with the bf2b7ac commit. The button now uses library logic (wasm) and shows up exactly when a rollback would do something. If I change library logic in the future, the frontend will adapt :-) |
Yorick reported on WhatsApp
The text was updated successfully, but these errors were encountered: