Skip to content

Commit

Permalink
Add game mode selection guide
Browse files Browse the repository at this point in the history
  • Loading branch information
jkilopu committed Dec 24, 2020
1 parent 1c848f0 commit 89d7a4b
Showing 1 changed file with 23 additions and 26 deletions.
49 changes: 23 additions & 26 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ Imitaion of classic game "Mines" using SDL2 library, with timer and flag.

## Gameplay

### Basic Gameplay

In the menu, you can determine the map width, height and the number of mines.

Once the game starts, you can use the mouse to click on blocks. The left click will open the block, the right click will set a flag on the block.
Expand All @@ -14,6 +16,27 @@ On the right side of the game window, the time spent will be shown.

Sweep all the mines(open all the blocks which can be opened) to win!

### Game Mode

The mode of the game is set according to the number of args:
1 for local mode, 2 for server mode, 3 for client mode.

#### Local mode
There must be no arg.
``` bash
./mymines
```

#### LAN mode
* Server mode
``` bash
./mymines <port>
```
* Clinet mode
``` bash
./mymines <IP> <port>
```

## Requirements

* C/C++ compiler(gcc, MSVC, mingw-gcc)
Expand All @@ -39,29 +62,3 @@ cd ..
### Visual Studio 2019 with CMake

### Visual Studio Code with CMake


## Play

The mode of the game is set according to the number of args.
In lan mode, you must specify IP address at the second argument.

### Local mode
There must be no arg.
``` bash
./mymines
```

### LAN mode

#### Server mode
Two args is needed.
``` bash
./mymines <whatever> <whaterver>
```

#### Clinet mode
One arg is needed.
``` bash
./mymines <IP>
```

0 comments on commit 89d7a4b

Please sign in to comment.