Skip to content

End of game is not handled #8

Description

@StevenInfinity

After 1 player wins the loop is still running and finally ends in error. The following errors was obtained

Traceback (most recent call last):
File "C:/Users/chainreaction.py", line 243, in
gameLoop()
File "C:/Users/chainreaction.py", line 220, in gameLoop
addAtom(i, j, players[currentPlayer])
File "C:/Users/chainreaction.py", line 137, in addAtom
overFlow(grid[i][j], color)
File "C:/Users/chainreaction.py", line 147, in overFlow
overFlow(cell.neighbors[m], color)
File "C:/Users/chainreaction.py", line 147, in overFlow
overFlow(cell.neighbors[m], color)
File "C:/Users/chainreaction.py", line 147, in overFlow
overFlow(cell.neighbors[m], color)
[Previous line repeated 1018 more times]
File "C:/Users/chainreaction.py", line 141, in overFlow
showPresentGrid()
File "C:/Users/chainreaction.py", line 104, in showPresentGrid
for i in range(cols):
RecursionError: maximum recursion depth exceeded in comparison

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions