Table of Contents
This document provides an overview of the application.
It outlines the use cases, i.e. desirable functionality, in addition to requirements for the smart contract and the user interface.
This section contains general information about the functionality of the application and thus does not touch upon any technical aspects.
If you are interested in a functional overview then this is the section for you.
- Initializes a new game with 2 players and resets the previous state.
- Reverts when:
- A game has not finished.
- Allows a player to place a marker on the game board.
- Checks if the move ends the game with either one player winning or a draw.
- Reverts:
- When the game has already ended.
- If the incorrect player tries to make a move.
- If a player tries to make a move out of bounds.
- If a player tries to make a move to an occupied cell.
View function to return the player positions in the current game.
View function to return the current state of the game.
View function to return the player who's turn it is to make a move.
View function to return the players of the current game.