# The &skladnik; Handbook

## Introduction

The first sokoban game was created in 1982 by Hiroyuki Imabayashi at the Japanese company Thinking Rabbit, Inc. Sokoban is Japanese for warehouse keeper. The idea is that you are a warehouse keeper trying to push crates to their proper locations in a warehouse.

The problem is that you cannot pull the crates or step over them. If you are not careful, some of the crates can get stuck in wrong places and/or block your way.

It can be rather difficult just to solve a level. But if you want to make it even harder, you can try to minimize the number of moves and/or pushes you use to solve the level.

To make the game more fun for small kids (below 10 years or so), some collections with easier levels are also included in &skladnik;. These are marked (easy) in the level collection menu. Of course, these levels can be fun for adults too, for example if you don't want to expose yourself to too much mental strain.

## The Game

The objective of the game is to push all the red gems to the goal squares, which are marked with green glassy round things on the floor.

Use the cursor keys or the mouse to move about. If you move onto a gem using the cursor keys or the &MMB;, and there is nothing blocking it on the opposite side, then you will push the gem. It isn't possible to pull the gems, so if you push a gem into a corner it will be stuck there. You cannot step over the gems either, so you can also get trapped in a part of the maze by blocking the way with gems. Also note that it isn't possible to push more than one gem at a time.

If you notice that you have moved the gems in such a way that the level is impossible to solve, then you can always use the undo feature to go back to a position where the mistake has not yet been made. You can of course also restart the level from the very beginning.

### Controls

Key | Action
Cursor keys | Move one square in a direction
&Ctrl;Cursor keys | Move as far as possible in a direction without pushing any gems
&Shift;Cursor keys | Move as far as possible in a direction, pushing any gem in the way
Left mouse button | Move to any place in the maze that can be reached without pushing any gems
Middle mouse button or &Ctrl;Z | Undo the last move
Right mouse button | Move up/down/left/right in a straight line, pushing any gem in the way
Mouse wheel | Traverse the history
&Ctrl;&Shift;Z | Redo the last undone move
N | Go to the next level in the current level collection
P | Go to the previous level in the current level collection
&Esc; | Restart the current level
&Ctrl;Q | Quit the game

### Loading external levels

&skladnik; has the ability to load external sokoban levels from text files. You can load levels using the Game Load Levels… menu item, or by specifying the level file &URL; as a command line argument when starting &skladnik; from a shell.

The external levels must be defined using the standard characters shown in the table below. If the file contains more than one level, the levels should be separated by blank lines. The file may also contain text between the levels.

Character | Meaning
`#` | Wall
(space) | Empty square
`.` | Goal square
`$` | Object on an empty square
`*` | Object on a goal square
`@` | Start position on an empty square
`+` | Start position on a goal square

As an example, below is a text representation of the first level in the Microban level collection:

    ####
    # .#
    #  ###
    #*@  #
    #  $ #
    #  ###
    ####

## Menu Reference

This is a complete guide to the menus of &skladnik;.

### The Game Menu

Game Load Levels…

- Load an external level. See the section Loading External Levels for more information.

N Game Next Level

- Load the next level.

P Game Previous Level

- Go back to the previous level.

&Esc; Game Restart Level

- Restart the current level.

Game Level Collection

- A submenu to switch to a different set of levels. &skladnik; comes with several level sets, and you can load more that you can find on the internet.

&Ctrl;Z Game Undo

- Undo the last move.

&Ctrl;&Shift;Z Game Redo

- Redo the last move you undid with the menu item above.

&Ctrl;Q Game Quit

- Exit &skladnik;.

### The Animation Menu

This menu offers menu items with check boxes that allow you to specify the speed to which the movement replay animations are shown at.

Animation Slow

- Show replay animations at a slow pace.

Animation Medium

- This is the default setting, and shows replay animations at a slightly faster pace.

Animation Fast

- Show replay animations at the fastest pace.

Animation Off

- Do not animate replay animations.

### The Bookmarks Menu

Bookmarks Set Bookmark

- &skladnik; allows you to set bookmarks with a level at a particular state. You might use this to save yourself repeating the same initial steps in a level.

  You can have up to ten bookmarks at a time, and access them via the &Ctrl;`X` shortcut, where `X` is any digit between 0 and 9.

Bookmarks Go to Bookmark

- Jump to a state you have previously saved as a bookmark.

### The Help Menu

&skladnik; has the common &kde; Help menu item, for more information read the section about the Help Menu of the &kde; Fundamentals.

## Credits and License

&skladnik; is copyright © 1998-2000 by &Anders.Widell; &Anders.Widell.mail;.

The background graphics starfield was taken from the Gimp. All other graphics were created by &Anders.Widell; &Anders.Widell.mail; using the Povray ray tracer.

All the currently included sokoban levels were created by David W. Skinner sasquatch@bentonrea.com. See his sokoban page.

&underFDL; &underGPL;
&documentation.index;