thelowman / mines

A simple javascript minesweeper game.
MIT License
0 stars 0 forks source link

Timer bug #2

Open thelowman opened 3 years ago

thelowman commented 3 years ago

The timer can get out of sync. One way to reproduce is to start a game, hit a mine and quickly pause the game. The timer will reset on starting a new game but the interval that drives the timer is still running.

thelowman commented 3 years ago

After some recent changes in the main javascript file I can't seem to reproduce this behavior any more.

thelowman commented 3 years ago

Found a new way to get the timer to mess up.

Start a new game, then when the grid shows up pause the game. Immediately the timer shows NaN. It will stay reading NaN for the rest of the game. On the next game the timer works but starts immediately and will not pause if the game is paused.