Open WindowsKonon1337 opened 1 week ago
Hello, thanks for this pull request. I understand your approach to solve the issue. Unfortunately the issue still happens, for instance, when starting a new game on a 8x8 board with 97% of the mines.
I was thinking of solving the issue on this method https://github.com/Bollos00/LibreMines/blob/9cf52ae171e9afbb1d58f22dfd3b4e3219cc90db/src/libreminesgameengine.cpp#L545
When the user clicks any cell, this method is triggered. The variable bFirst
indicates wheter it is the first time the user is clicking on any cell. On there, it is calling vNewGame and being stuck because there is no way a cell may have all its neighbors free of mine if nMines > (iX*iY - 9)
.
So a solution in this, I believe, would be not call vNewGame
given that condition.
solution for this issue