The KMahjongg Handbook

# The KMahjongg Handbook

John Hayes `<justlinux@bellsouth.net>`

Eugene Trounev `<eugene.trounev@gmail.com>`

Revision 0.9 (KDE Gear 21.04) (2021-06-16)

Legal Notice

This documentation describes the game of KMahjongg version 0.9

List of Tables

6.1. Keyboard Shortcuts

Chapter 1. Introduction
Introduction

# Chapter 1. Introduction

### Gametype:

Board, Arcade

### Number of possible players:

One

KMahjongg is a fun board game created after the famous oriental game of Mahjong (from Chinese 麻將). Unlike the original however, KMahjongg is a tile matching game for one player, a variation usually known as Mahjong Solitaire.

In KMahjongg the tiles are scrambled and stacked on top of each other to resemble a certain shape. The player is then expected to remove all the tiles off the game board by locating each tile's matching pair.

Chapter 2. How to play
How to play

# Chapter 2. How to play

### Objective:

Remove all tiles from the game board by locating each tile's matching pair as fast as possible.

KMahjongg will load a default layout automatically once you start the game and you can start playing right away.

### Note:

The game timer will start immediately if the game is started.

You should carefully study the stack of tiles laid out on the game board and find two tiles matching exactly. When you have found such a pair use your mouse to select these.

### Note:

Bear in mind that you can only select the tiles which are “Open”. Tiles are considered “Blocked” when they are positioned behind other tiles, or when both the right and left sides of the tile are filled by others. If at least one of the lateral sides is empty then the tile is considered “Open”, and can be removed.

Once you have selected the right pair of tiles they will vanish off the game board, thus revealing the tiles previously located underneath, and opening the tiles adjacent to them.

Find as many matches as possible to remove all the tiles from the game board.

Chapter 3. Game Rules, Strategies and Tips
Game Rules, Strategies and Tips

# Chapter 3. Game Rules, Strategies and Tips

## The Game Screen

A quick explanation of the parts of the game screen.

Game Screen

  The Game screen is in the center of the screen and is the largest section of the window. The background is populated with the game tiles.

Statusbar

  The status bar is located at the bottom of the screen, and contains four panes. The first pane displays the game timer, which keeps track of the elapsed time from the start of the game until the game is finished. The second pane lists the removed/total tiles and the number of matching tiles that have free sides. The third pane gives the sequence number of the game you are playing and the last pane lets the player know when the game is ready.

Rules
Rules

## Rules

Standard Mahjong set of tiles includes:

Group name | Tile name | Quantity in a set
Dots |  |
| 1 of Dots | 4
| 2 of Dots | 4
| 3 of Dots | 4
| 4 of Dots | 4
| 5 of Dots | 4
| 6 of Dots | 4
| 7 of Dots | 4
| 8 of Dots | 4
| 9 of Dots | 4
Bamboos |  |
| 1 of Bamboos | 4
| 2 of Bamboos | 4
| 3 of Bamboos | 4
| 4 of Bamboos | 4
| 5 of Bamboos | 4
| 6 of Bamboos | 4
| 7 of Bamboos | 4
| 8 of Bamboos | 4
| 9 of Bamboos | 4
Characters |  |
| 1 of Characters | 4
| 2 of Characters | 4
| 3 of Characters | 4
| 4 of Characters | 4
| 5 of Characters | 4
| 6 of Characters | 4
| 7 of Characters | 4
| 8 of Characters | 4
| 9 of Characters | 4
Winds |  |
| East Wind | 4
| South Wind | 4
| West Wind | 4
| North Wind | 4
Dragons |  |
| Red Dragon | 4
| Green Dragon | 4
| White Dragon | 4
Flowers |  |
| Plum (1) | 1
| Lily (2) | 1
| Chrysanthemum (3) | 1
| Bamboo (4) | 1
Seasons |  |
| Spring (1) | 1
| Summer (2) | 1
| Autumn (3) | 1
| Winter (4) | 1

- The number of tiles on a KMahjongg board layout can differ from the number of tiles in the standard Mahjong tile set. That means that the number of occurrences of tiles of the same type can also differ from the number stated in the table above.

- Only the “open” tiles can be selected.

- “Open” tile is the tile which has one of the tile's lateral sides open, meaning that no other tiles are located immediately next to it.

- Only when matching, open tiles can be removed from the game board.

- Matching tiles are those where the face pictograms match.

### Note:

There are exceptions to this rule! In the traditional game of Mahjong each tile has a matching one except for the “Flowers” and “Seasons” tiles.

- The “Flowers” tiles have no doubles in the set and can be matched directly to each other.

- The “Seasons” tiles have no doubles in the set and can be matched directly to each other.

- Not every KMahjongg game can be finished. Sometimes the tiles are mixed in such a way that it may not be possible to find all the matches. This problem can be avoided. Please refer to this section of the configuration dialog.

- To be eligible for a place amongst the high scores the player has to complete a game instance within the shortest period of time possible.

### Note:

If the player uses the “Hint” feature the record will not be considered as a high score.

Chapter 4. Interface Overview
Interface Overview

# Chapter 4. Interface Overview

## Menu Items

Game → New (Ctrl+N)

  Starts a new game.

Game → Load… (Ctrl+O)

  Loads a saved game.

Game → Restart Game (F5)

  Restarts the current game.

Game → New Numbered Game…

  Starts a specifically numbered game.

Game → Save (Ctrl+S)

  Saves the current game.

Game → Pause (P)

  Pauses or resumes the game. While the game is paused, all tiles are hidden.

Game → Show High Scores (Ctrl+H)

  Shows the high score list.

  When your game scores exceed the top ten scores listed, you are prompted to enter your name.

Game → Board Editor

  Shows the board editor.

  Procedure to edit layout:

  1. Use the board editor toolbar to create a new layout or to load and edit an existing one.

  2. Save the layout in your user's local home folder in `$`XDG_DATA_HOME`/kmahjongg/layouts`

  3. Create the ``name_of_your_layout`.desktop` file in the same folder.

  4. Put the following lines in this file using your favorite text editor:

         [KMahjonggLayout]
         Name=name_of_your_layout
         Description=description_of_your_layout
         VersionFormat=1
         Author=your_name
         AuthorEmail=your_email
         FileName=name_of_your_layout.layout

  5. Reload KMahjongg to use your new layout.

Game → Quit (Ctrl+Q)

  Quits KMahjongg.

Move → Undo (Ctrl+Z)

  Undo your last move.

Move → Redo (Ctrl+Shift+Z)

  Redo a move that was undone.

Move → Hint (H)

  Gives a Hint by flashing a matching pair of tiles.

Move → Demo (D)

  Starts the game Demo mode.

Move → Shuffle

  Shuffles the tiles on the board.

View → Rotate View Clockwise (G)

  Rotates the tile viewing angle clockwise.

View → Rotate View Counterclockwise (F)

  Rotates the tile viewing angle counter clockwise.

Additionally KMahjongg has the common KDE Settings and Help menu items, for more information read the sections about the Settings Menu and Help Menu of the KDE Fundamentals.

Chapter 5. Frequently asked questions
Frequently asked questions

# Chapter 5. Frequently asked questions

5.1. I want to change the way this game looks. Can I?
5.2. Can I use the keyboard to play the game?

5.1. | I want to change the way this game looks. Can I?
| Yes. To change the way KMahjongg looks use the menubar to open the configuration utility.
5.2. | Can I use the keyboard to play the game?
| No. This game does not feature a keyboard play mode yet.

Chapter 6. Game Configuration
Game Configuration

# Chapter 6. Game Configuration

Settings → Configure KMahjongg… opens the Configure - KMahjongg dialog.

## General options

Blink matching tiles when first one is selected

  This setting will make the game highlight the selected tile on mouse click, and flash any matching tiles that have a free side at each move. No additional tiles will be highlighted if there are no matching tiles with a free side.

Generate solvable games

  Selects only games that can be solved when you start a new game.

Show removed tiles

  If checked, this setting allows KMahjongg to show the removed tiles on the board.

Board layout options
Board layout options

## Board layout options

Random Layout

  Every new game will have a random layout of the existing one in the list.

Board Layout selector

  Use the Board Layout selector to pick a gameboard to play. Different boards provide variable difficulty, depending on the number of tiles and their position.

Tiles options
Tiles options

## Tiles options

Tiles selector

  Use the Tiles selector to choose graphics for the tiles.

Background options
Background options

## Background options

Background selector

  Use the Background selector to choose a background graphic for the game.

Default Keybindings
Default Keybindings

## Default Keybindings

Settings → Configure Shortcuts… allows you to change the default keyboard bindings.

The default kebindings are as follows:

Table 6.1. Keyboard Shortcuts

Key Combo | Action
--- | ---
Ctrl+N | Starts a new game
Ctrl+O | Loads a previously saved game
F5 | Restart the game
Ctrl+S | Saves the game
P | Pauses or resumes a game
Ctrl+H | Show the highscores
Ctrl+Q | Quits the game
Ctrl+Z | Move undo
Ctrl+Shift+Z | Move redo
H | Gives you a hint by flashing two matching tiles
D | Plays the game in Demo mode
G | Rotate the view angle clockwise
F | Rotate the view angle counter-clockwise
F1 | Displays this handbook
Shift+F1 | What's This Help

Chapter 7. Credits and License
Credits and License

# Chapter 7. Credits and License

KMahjongg by KDE

Program Copyright (c) 1997 Mathias Mueller `(in5y158 AT public.uni-hamburg.de)`

Program Copyright (c) 2007 Mauricio Piacentini `(piacentini AT kde.org)`

Contributors:

- David Black `(david.black AT lutris.com)`

- Michael Haertjens `(mhaertjens AT modusoperandi.com)`

- Osvaldo Stark `(starko AT dnet.it)`

- Benjamin Meyer `(ben+kmahjongg AT meyerhome.net)`

- Albert Astals `(aacid AT kde.org)`

- Raquel Ravanini `(raquel AT tabuleiro.com)`

Documentation Copyright (c) 2005 John Hayes `(justlinux AT bellsouth.net)`

This documentation is licensed under the terms of the GNU Free Documentation License.

This program is licensed under the terms of the GNU General Public License.