7xGit / 7xGit/7xGit_Task3

Turn Skipping After Invalid Move

Ouverte Adaptée aux débutants
#3 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
bug enhancement
Langage dominant
C++
Étoiles
1
Forks
4
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

Title:
Turn Counting Error After Invalid Input

Description:
After an invalid move (e.g., selecting a position that's already taken or out of bounds), the game asks the player to try again, but the turn counter still increments. This causes the turn to skip, giving the other player two turns in a row.

Steps to Reproduce:

Start the game.
Make an invalid move by choosing a taken or out-of-bounds cell.
Observe that after re-entering the move, the other player gets two turns.
Expected Behavior:
The game should not increment the turn count when the input is invalid.

Suggested Fix:
Ensure the turn counter only increments when the input is valid.

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

Look for the game loop and turn-handling logic, likely in a main game file. Identify where the turn counter is incremented and where input validation occurs. Ensure the increment only happens after a valid move is confirmed. Run the game and test with invalid moves to verify the fix.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
cpp
Domaine
game-dev
Type d'issue
Bug
Difficulté
2/5
Temps estimé
1-3 heures
Activité
À l'abandon
Clarté
Clairement spécifiée
Accessibilité débutants
70/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.