Skip to content

Commit

Permalink
Add files
Browse files Browse the repository at this point in the history
  • Loading branch information
sherwin-dc committed Dec 22, 2020
1 parent 544c314 commit 7fa4b43
Show file tree
Hide file tree
Showing 8 changed files with 61 additions and 0 deletions.
Binary file added Minesweeper.xls
Binary file not shown.
61 changes: 61 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
## Overview

Need a break from work? Unable to install any games? Introdcing VBA Minesweeper!

This is an old game which I had created in the past during my free time in my previous workplace, and am putting it online for everyone to play.

![Game](media/Game.png)

## Features

- Unique maps randomly generated at the start of game
- Tiles surrounding empty spaces are opened automatically
- In game timer
- Flag tiles as possibly being mines
- Custom games with specifiable map size (from 2x2 to 500x500) and number of mines

## Requirements

Microsoft Excel with macros enabled. This was created using a 2010 version of Excel on Windows, but is likely to work on much older versions as well.

## Code

To view the code press `Alt` and `F11` to open the VBA editor.

## How to play

After opening the document, ensure that macros are enabled. Click on `Start / Reset` to bring up the menu.

### Quick Start

Click on the `Simple` tab.

1. Select a map size, which ranges from a 10x10 grid to a 50x50 one.
2. Select a difficulty level which determines the percentage of tiles that are filled with mines.
3. Click start to begin the game.

![Start](media/Quick-Start.png)

### Custom Gameplay

Click on the `Custom` tab.

1. Enter the desired width and height for the map size. Maps of up to 500x500 can be made.
2. Enter the number of mines.
3. Click start to begin the game.

![Custom](media/Custom.png)

### Instructions

In game instructions are available and can be accessed from the `Instructions` tab.

![Instructions](media/Instructions.png)

### Finishing a game

A game is finished either by opening all non-mine tiles or by opening a mine. This is followed by a message with the time taken, tiles opened and number of mines present.

![Win](media/Win.png)

![Loss](media/Loss.png)
Binary file added media/Custom.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/Game.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/Instructions.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/Loss.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/Quick-Start.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added media/Win.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 7fa4b43

Please sign in to comment.