3 ms·
What a convoluted solution. I always assumed it did things the way I did when I wrote my minesweeper game: it only generated the mines on the first click, avoi
by lelanthran 2y ago
What a convoluted solution.
I always assumed it did things the way I did when I wrote my minesweeper game: it only generated the mines on the first click, avoiding the clicked tile.
I wonder why they did it that way?
- Shadowed_ 2y agoI don't know for sure, but they probably didn't plant it at first and later it was simpler to move mine elsewhere than to change the way mines are generated.
- SAI_Peregrinus 2y agoProbably performance. It's an old game, it seems faster if the mines can get generated before the user first clicks, and then move the mine if their first click was on a mine. If you wait for them to click to generate then the entire generation step has to run before the user notices.