We’ve all played the standard windows minesweeper when bored, but only those who have programmed a clone have a truly deep understanding and appreciation of the game. As my final project in a Java course I took, I programmed this game. I even took it a little above and beyond adding some of the little perks like an animated character, ability to do the ‘both click’ and other features.
Unfortunately, I lost the source code somewhere in the digital vortex. Therefore, I can only show screenshots and allow interested persons to download and play the game.
Java Minesweeper has been featured on several download sites:
This game is almost exactly the same as the original minesweeper that is common to all of us. I even added all of the little features that allow you to play fast. Things like clicking both mouse buttons so that if a tile already has all of its mines flagged, it uncovers all of the adjacent tiles. I also put Duke as the animated character. He turns bright red when he’s worried, cheers when you win and dies when you step on a mine.
Things I learned
I’ll tell all of you in the world this: If you want to get SICK of playing a game, program it and try to debug it! I must have played a gizzilion games of minesweeper.
Also, keep up with source code for really cool projects you make! I didn’t and I’m really upset. I had big plans for this little guy. I had made it so that you could change the levels with a re-compile and re-setup of initial constants and was planning to add that feature, but didn’t get around to it before then. So, sorry everyone who was hoping to look at the source.
Another thing I learned was how easy and relevant object-oriented programming is. I feel that doing projects like this really helps to drive home concepts and ideas about programming far more than coding up *another* tree traversal algorithm.
As promised, I have below a fully playable .jar file. Just download, unzip, and double click the .jar. If you have Java installed it should run no-problem.