<?xml version="1.0" ?>
<!DOCTYPE book PUBLIC "-//KDE//DTD DocBook XML V4.1-Based Variant V1.0//EN" "dtd/kdex.dtd" [
<!ENTITY kappname "&kwin4;">
<!ENTITY % English "INCLUDE"> 
<!ENTITY % addindex "IGNORE">
]>

<book lang="&language;">
<bookinfo>
<title>Four Wins</title>

<authorgroup>
<author>
<firstname>Martin</firstname>
<surname>Heni</surname>
<affiliation>
<address><email>martin@heni-online.de</email></address>
</affiliation>
</author>

<othercredit role="reviewer">
<firstname></firstname>
<surname></surname>
<contrib>Reviewer</contrib>
<affiliation><address><email></email></address></affiliation>
</othercredit>

<!-- TRANS:ROLES_OF_TRANSLATORS -->

</authorgroup>

<date>2001-06-23</date>
<releaseinfo>0.09.01</releaseinfo>

<abstract>
<para>
This documentation describes &kwin4; version 0.9.1</para>
</abstract>

<keywordset>
<keyword>KDE</keyword>
<keyword>kdegames</keyword>
<keyword>game</keyword>
<keyword>board</keyword>
<keyword>board game</keyword>
<keyword>four wins</keyword>
<keyword>four</keyword>
<keyword>four in a row</keyword>
<keyword>win4</keyword>
<keyword>kwin4</keyword>
<keyword>connect four</keyword>
<keyword>connect 4</keyword>
</keywordset>
</bookinfo>

<chapter id="overview">
<title>Overview</title>

<para>
Four wins is a game for two players.
</para>

<para>
Each player is represented by a color (yellow and red).  The goal of the
game is to get four connected pieces of your color into a row, column or
any diagonal.  This is done by placing one of your pieces into any of
the seven columns.
</para>

<para>
A piece will begin to fill a column from the bottom, &ie; it
will fall down until it reaches the ground level or another stone.
After a move is done it is the turn of the other player.
</para>

<para>
This is repeated until the game is over, which is when one of the
players has four pieces in a row, column or diagonal or no more moves
are possible because the board is filled.
</para>

</chapter>

<chapter id="rules">
<title>Rules</title>

<para>
The board is separated into three regions.
</para>

<para>
The <firstterm>game board</firstterm> is constructed out of 7x6 fields
which will be filled from bottom to top. The fields are marked in the
color of the player who made the current move.  On top of each column a
colored arrow shows were the last piece had been put.
</para>

<para>
The <firstterm>status display</firstterm> shows which player color
starts and which color is played by whom (player, computer, remote
connection). It further shows the level of the computer opponent, the
number of moves done as well as the computer calculated chance of
winning. This chance is calculated only if the computer opponent makes a
move. A positive number means that the player has an advantage, a
negative number means that the computer thinks he is better.
</para>

<para>
The <firstterm>table display</firstterm> shows the number of won, lost
and drawn games is noted for both player.  Also the number of aborted
games (Brk) and the sum of games is shown.
</para>

</chapter>

<chapter id="remote-connections">
<title>Remote connections</title>

<para>
It is possible to play the game over a network connection with another
computer. To do so both player on both computers have to select one
color played by a human player and the other by the remote player. Who
chooses which side does not matter. It even does not matter if both
choose to play the same player as this will automatically be
interchanged by the game.
</para>

<para>
One of the computers will act as game server. Only this one can start a
new network game. Also all its game data will be transfered to the
client computer. You can force your computer to be server if you do not
supply a hostname in the network dialog. This dialog pops up if you
start a new network game. As a client you enter the hostname of the
machine the server is running. The port rarely needs to be changed, but
you can enter nearly any number there.
</para>

<para>
When a network connection is build you are asked to enter a remote host
and a port. The port can usually just be left untouched, but if you know
what you are doing replace it by another number, which has to be the
same in both player games of course. The hostname should be the name of
the remote host to which you are connecting. Only one of the two players
has to supply a hostname, the other one doesn't need to, but can.
</para>

</chapter>

<chapter id="menus">
<title>Menus</title>

<sect1 id="game-menu">
<title>Game Menu</title>

<variablelist>
<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>N</keycap></keycombo>
</shortcut>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem><accel>N</accel>ew Game</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Starts a new game. In a network game this option is only available for
the network server. The network client will be automatically started by
the server.  
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem><accel>E</accel>nd Game</guimenuitem></menuchoice></term>
<listitem>
<para>
Aborts a running game.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem><accel>S</accel>how Statistics...</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Shows the all time game statistics and allows to reset it.  This
statistic is usually saved when the game ended and shows the amount of
played and won games per player. 
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>H</keycap></keycombo>
</shortcut>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem><accel>H</accel>int</guimenuitem>
</menuchoice></term>
<listitem>
<para>
The computer will calculate the best possible move and mark it with a
small circle on the board.  How good the move is depends on the level of
the computer.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>M</keycap></keycombo>
</shortcut>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem>Send <accel>M</accel>essage</guimenuitem>
</menuchoice>
</term>
<listitem>
<para>
If connected to another game in a remote session this option allows you
to send a message to the remote player.
</para>
</listitem>
</varlistentry>


<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>Q</keycap></keycombo>
</shortcut>
<guimenu><accel>G</accel>ame</guimenu>
<guimenuitem><accel>Q</accel>uit</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Quits the program.
</para>
</listitem>
</varlistentry>
</variablelist>

</sect1>

<sect1 id="edit-menu">
<title>Edit Menu</title>
<variablelist>
<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>Z</keycap></keycombo>
</shortcut>
<guimenu><accel>E</accel>dit</guimenu>
<guimenuitem>Und<accel></accel>o</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Undo the last move. If the previous player is played by the computer two
moves are taken back so that it is the player's turn again.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;&Shift;<keycap>Z</keycap></keycombo>
</shortcut>
<guimenu><accel>E</accel>dit</guimenu>
<guimenuitem>Re<accel>d</accel>o</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Replay a move which had been undone.
</para>
</listitem>
</varlistentry>
</variablelist>

</sect1>

<sect1 id="view-menu">
<title>View Menu</title>

<variablelist>
<varlistentry>
<term><menuchoice>
<guimenu><accel>V</accel>iew</guimenu>
<guimenuitem><accel>S</accel>how Statusbar</guimenuitem>
</menuchoice></term>
<listitem>
<para>
Toggle on and off the display of the status bar.
</para>
</listitem>
</varlistentry>
</variablelist>
</sect1>

<sect1 id="option-menu">
<title>Options Menu</title>

<variablelist>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guisubmenu>Startplayer</guisubmenu>
</menuchoice></term>
<listitem>
<para>
Determines which color player  has the first move in the next game.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guisubmenu>Yellow played by</guisubmenu>
</menuchoice></term>
<listitem>
<para>
Chooses who should play for player 1 (yellow). It can be either
<guimenuitem>player</guimenuitem>, &ie; a local player using the mouse
as input device, <guimenuitem>computer</guimenuitem>, &ie; the computer
plays this player or <guimenuitem>remote</guimenuitem>, &ie; a remote
connection to another computer will be build.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guisubmenu>Red played by</guisubmenu>
</menuchoice>
</term>
<listitem>
<para>
Same as <guimenuitem>Player 1 played by</guimenuitem> but for player 2
(red).
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guisubmenu><accel>L</accel>evel</guisubmenu>
</menuchoice></term>
<listitem>
<para>
Selects the level of the computer player.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guimenuitem>Change <accel>N</accel>ames...</guimenuitem></menuchoice>
</term>
<listitem>
<para>
Change the names of the players.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>O</accel>ptions</guimenu>
<guimenuitem>Network server</guimenuitem>
</menuchoice></term>
<listitem>
<para>
If this menu item is selected your computer tries to behave as game
network server. This is of course only of any importance if you are
doing a network game.  Only the computer acting as server will be able
to start a new game or transfer a started game to the client's side.  If
both computers want to be server or none of them it is randomly
selected.  
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>Options</accel></guimenu>
<guimenuitem><accel>A</accel>nimations</guimenuitem>
</menuchoice>
</term>
<listitem>
<para>
Switches the animations on or off.
</para>
</listitem>
</varlistentry>
</variablelist>
</sect1>

<sect1 id="help">
<title>The <guimenuitem>Help</guimenuitem> Menu</title>

<variablelist>
<varlistentry>
<term><menuchoice>
<shortcut><keycombo action="simul"><keycap>F1</keycap></keycombo></shortcut>
<guimenu><accel>H</accel>elp</guimenu>
<guimenuitem>Contents</guimenuitem>
</menuchoice></term>
<listitem>
<para>
This invokes the &kde; help system starting at the the top of this help
file.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>H</accel>elp</guimenu>
<guimenuitem>Report Bug.</guimenuitem>
</menuchoice></term>
<listitem>
<para>
If you find an error in the program, or you have an idea on how to
improve the game, clicking this option will let you send an official bug
report to the &kde; team.
</para>

</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>H</accel>elp</guimenu>
<guimenuitem><accel>A</accel>bout KWin4</guimenuitem>
</menuchoice></term>
<listitem>
<para>
This will display version and author information.
</para>
</listitem>
</varlistentry>

<varlistentry>
<term><menuchoice>
<guimenu><accel>H</accel>elp</guimenu>
<guimenuitem>About <accel>K</accel>DE</guimenuitem>
</menuchoice></term>
<listitem>
<para>
This displays the &kde; version and other basic information.
</para>
</listitem>
</varlistentry>
</variablelist>
</sect1>

</chapter>

<chapter id="credits">
<title>Credits and License</title>

<para>
&kwin4;
</para>
<para>
Program copyright 1995-2001 Martin Heni <email>martin@heni-online.de</email>
</para>
<para>
Documentation copyright 2001 Martin Heni <email>martin@heni-online.de</email>
</para>

<!-- TRANS:CREDIT_FOR_TRANSLATORS -->

&underFDL;
&underGPL;

</chapter>

<appendix id="installation">
<title>Installation</title>

<sect1 id="getting-kwin4">
<title>How to obtain &kwin4;</title>

<para>
&kwin4; can be found in the package kdegames on <ulink
url="ftp://ftp.kde.org/pub/kde/">ftp://ftp.kde.org/pub/kde/</ulink>, the
main &FTP; site of the &kde; project.
</para>
</sect1>

<sect1 id="requirements">
<title>Requirements</title>

<para>
In order to successfully compile &kwin4;, you need &kde; 2.0
</para>

<para>
All required libraries as well as &kwin4; itself can be found on <ulink
url="ftp://ftp.kde.org/pub/kde/">ftp://ftp.kde.org/pub/kde/</ulink>.</para>
</sect1>

<sect1 id="compilation">
<title>Compilation and Installation</title>

<para>
In order to compile and install &kwin4; on your system, extract the
package and type the following commands in the base directory of the
&kwin4; distribution:
</para>

<screen width="40">
<prompt>%</prompt> <userinput>cd kdegames</userinput>
<prompt>%</prompt> <userinput>./configure</userinput>
<prompt>%</prompt> <userinput>make</userinput>
<prompt>%</prompt> <userinput>make install</userinput>
</screen>

<para>
Since &kwin4; uses <command>autoconf</command> and
<command>automake</command> you should have no trouble compiling it.
</para>

</sect1>
</appendix>


&documentation.index; 
</book>
<!--
Local Variables:
mode: sgml
sgml-minimize-attributes:nil
sgml-general-insert-case:lower
sgml-always-quote-attributes:t
sgml-indent-step:0
sgml-indent-data:t
End:
-->

