generated from Arquisoft/yovi_0
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
The player loses the match if any of the following happens:
- The timer reaches zero and the player has not connected the three sides of the board.
- The opponent (bot) connects the three sides of the board before the player.
🔺 Win Condition
The player wins the match if:
They connect the three sides of the board before the timer reaches zero AND before the opponent connects their three sides.
Required Features
- Game End Detection
- Detect when the player or the bot completes a winning connection.
- Detect when the timer reaches zero.
- Trigger the end‑of‑game state accordingly.
- UI Feedback
When the match ends, the interface must display:
- A congratulatory message if the player wins.
- An encouraging message if the player loses.
Both outcomes must include two buttons:
- Exit → Navigates to the main page.
- Play Again → Navigates to the Game Preview screen.
- Data Persistence
The result of the match (win or loss) must be stored in the database.
This data will be used to:
- Update the global ranking.
- Display the match in the user's game history.
Acceptance Criteria
- The game ends correctly under all win/loss conditions.
- The correct message is shown depending on the outcome.
- Exit and Play Again buttons work as expected.
- Match results are saved and accessible for ranking and history.
- No match can continue indefinitely.
Reactions are currently unavailable