Closed tkshill closed 3 years ago
Thank you for the issue! We'll take your request into consideration and will follow up soon if we decide to tackle this issue.
To all contributors: any issue that is labeled Status: Available
is up for grabs.
To claim an issue to work on, please leave a comment. If you've claimed the issue and need help, please leave a comment letting us know and we can schedule some time to help.
For full info on how to contribute, please check out our contributors guide.
I'd like to take this on!
All yours my friend
Issue Context
Here we can see that the user can click a button even when it's the computer's turn to play. This should... not be so.
Suggested Solution
Behind the scenes, an active game exists in one of four turn states
Based on these types, the valid gamestatuses can be
Inplay Human ChoosingPiece
Inplay Computer ChoosingPiece
Inplay Human ChoosingCellToPlay ChosenPiece
Inplay Computer ChoosingCellToPlay ChosenPiece
Won Winner
Draw
Note that of these 6 options, the only time a game piece should be selectable is the first one, when a person is choosing a piece.
The view logic in
Top.elm
will have to be modified so the buttons are disabled except when the game is that specific turn state.Alternatives Considered
Additional Resources
See here in the read me for how to run and install the application.
See here in contributing for the basics on forking and cloning the repository.