Minesweeper is a famous strategy game. The goal of the game is to open
all free fields, avoinding the bombs.
This game brings the binaries, sources and a development manual in
- MSX 2 or greater;
- Clock chip;
- MSX-DOS 1.
Avoid mines number and clock display flicker; - Ok
Open the 8 neighbors, when some number is clicked; - Ok
Assembly routine to control time; -Ok
Fix bomb random sorting;
Create winners ranking; - Ok
Save this rank on disk. - Ok
2. How to play
- Choose game type: easy (8x8 with 10 bombs) ou hard (16x16 with 40 bombs);
- Arrows move the cursor;
- Esc quits the game;
- Press ENTER when you win the game;
- Z detonate the space under the cursor;
- X flags the space under the cursor;
- C when clicked on a number, open its 8 neighbors, only if surround it the
corresponding number of flags were placed.
mines_src_11.zip - Sources.
mines_11.zip - Binaries.
map.pas - Code to create the game map.
flood.pas - Example of flood-fill.
start.asm - How to read MSX 2 clock in Assembly.
4. Development tutorial
The game development tutorial (Portuguese) was created in PDF format, containing the following topics:
- How to use MSX Pad
- The game Minesweeper
- Creating menu bars
- Creating the mines map
- Drawing the objects
- Assembling the "puzzle"
- The flood-fill algorithm
- The game control
- Calculating the time
- The ranking
- The random function bug
mandev11.pdf - Development manual version 1.1 (Portuguese) - May 2018.
Learn how to develop Minesweeper in Basic: Mines Basic.
References and Acknowledgements
Hans page: http://www.hansotten.com/msxpascal.html
Book on Turbo Pascal: http://oldcomputers.dyndns.org/public/pub/rechner/epson/~fjkraan/comp/tp30/doc/
Thanks to SLotman for MSX Pad, for the use of constants for maps and for the time.inc.