Random practice boards

Anything to do with minesweeper...
Post Reply
aradesh
Posts: 90
Joined: Sat Aug 29, 2009 3:37 pm

Random practice boards

Post by aradesh » Sat Aug 29, 2009 7:41 pm

Sometimes when I blast a game, or hesitate due to a certain situation I think, "Wouldn't it be nice if I could practice scenarios like this over and over?" So I end up upk'ing the board, but it isn't the same because I know exactly what's going to happen! So I decided it would be ideal if I could write a computer program which created random-looking boards but which are subtly filled with similar scenarios as to those I want to get better at - this way I get to practice the scenario in different contexts lots but not know when it's about to come up or where it is.
Sadly for almost all useful scenarios this is too difficult a task for me to do well! So I decided to do it with those "corridors" of safe squares you get at the edge of a board (the attached image should explain what i mean). These situations annoy me because every time you click you need to react to the result rather than having other squares to click on while you think.
I wrote a python script to generate a random corridor.mbf board every time you run it. I've had fun playing on them, although the fastest I seem to be able to do it in is about 33 seconds. If I go much faster I end up blasting due to not being able to react fast enough to the end of a corridor, though I think I could do it under 30 if I was lucky.
The python script is at http://pastebin.com/f42482874 if anyone is interested in trying it or making it better :P.
corridors.PNG
corridors.PNG (7.6 KiB) Viewed 1498 times

EWQMinesweeper
Posts: 410
Joined: Sun Nov 30, 2008 11:50 pm

Re: Random practice boards

Post by EWQMinesweeper » Sat Aug 29, 2009 10:01 pm

64 squares without mines...assume 1 tenth for every click, 2 tenths reaction time and 1 tenth to move to the next square plus 1 additional tenth when you see a mine and have to slow down a bit...

6.4s+12.8s+8.8s+2.4s...30.4s, a 31 is doable
„Das perlt jetzt aber richtig über, ma sagn. Mach ma' noch'n Bier! Wie heißt das? Biddä! Bidddää! Biddddäää! Reiner Weltladen!“

User avatar
Tommy
Posts: 223
Joined: Mon Dec 01, 2008 9:22 pm
Location: Vienna

Re: Random practice boards

Post by Tommy » Sun Aug 30, 2009 10:14 am

Yay, that's a project for me :D

I'll take some time to think about that soon. I'd guess that the hardest part is representing the standard situations. If you code that well, though, you have something like regexes for parts of minesweeper boards, only that you're not matching but generating - but that could be reversed for board analysis :D

I'm on it ;)
Don't anthropomorphize computers - they don't like it.

Post Reply