                             glGo Playermanager 0.4
                             ----------------------

About
-----

This is an add-on for the glGo and gGo clients to edit the player database.

If you run Linux, you need to install Python (usually already installed) and wxPython.
The Windows and Mac OS X versions already include all required Python libraries.

There are two executables: players.exe and players_gui.exe for Windows, players.py
and players_gui.py for Linux or Mac. players(.exe|.py) is the commandline interface,
try the "--help" parameter to see how it works. players_gui(.exe|.py) starts the GUI.

If you have an idea for cool a feature what the player database should do, please
let me know! The Ambassador IGS client has some player database related features
which are pretty interesting.

Please see the glGo documentation for details about this package. It makes
absolutely no sense to install this software without the glGo or gGo client.


Usage
-----

The player database can store players, assign them a status (Friend, Neutral, Bozo),
a comment and up to 5 customized flags. There are several ways to add a player to the
database. Most obvious, use the "Add" button in the playermanager. Additionally, if
you set someone to friend/bozo status or assign a comment or flags from the glGo
player dialog or the playertable popup menu, the player will automatically be added
to the database. To remove a player, use the "Remove" button in the playermanager.

The status "Friend" will show the player when you enable the "Friends" filter in the
glGo player table. "Bozo" will block incoming tells, match requests, shouts and
kibitzes of this player.

The customized flags have no certain effect, you can assign whatever you want. For
example to create a flag "Escaper", select "Edit flags" in the "Edit" menu of the
playermanager, type "Escaper" in one of the 5 slots, and enable the checkbox near
this flag. Close the dialog and double-click on one of the players, and you will
see the new Escaper flag. You can set this flag for each player both in the player-
manager and in the glGo playerinfo dialog. Sounds complex? Just try it, it should
be fairly obvious.
Please note a flag is stored not by the name of the flag, like "Escaper" but by
the slot number. So for example if you name flag #1 "Escaper" and assign it to
a couple of players, then later rename flag #1 to "Cool dude", the players formerly
assigned as "Escaper" will now be "Cool dudes" because they have their flag #1 set.
The name of a custom flag should be unique.

The comment has no special effect, you can write down whatever you want for a player
or just leave it empty. It might be a good idea not to write several pages of text
there. Some lines will work without problem.

There is a "Cleanup" available in the playermanager. This will remove all entries
which are not set to friend or bozo, have no comment and no custom flags assigned.
In short, those entries contain no data. They could be created by assigning
a flag or comment to a player and later removing it again, then the player itself
will not automatically be removed from the database.

glGo and the playermanager access the same database file. It is possible to edit the
database in the playermanager while glGo is running. glGo will detect changes and
automatically reload the database if necassary.
The playermanager will not detect changes made in glGo, there is a "Reload" button
available to check if the database needs to be reloaded.

You can scan directories for SGF files. The SGF headers will be parsed and the
information stored in an index file. When you open the dialog for a certain
player you will get a table with all games found with this player. This feature
is meant for interaction with autosave in glGo. Additionally (or instead) you could
index your games with Kombilo, if you plan to do some serious studies.
The game tables can be sorted, left/right click on the column headers.
The "Cleanup games" menuitem will look for entries without SGF file and remove the
entry. This is useful if you manually deleted some SGF files from previously scanned
directories.
When you add new SGF files to the previously scanned directories, Playermanager
won't add them automatically to its index, so you need to manually rescan the
directory. An exception to this is when glGo autosaves games, those will be added
to the Playermanager games index automatically.
Games can be opened in glGo by double-clicking on a row in the table. This requires
the localserver meachnism in glGo enabled (and possibly some firewall tweaking on
Windows). On Mac there is no localserver mechanism in glGo, opening games in glGo
works different on Mac than on Linux and Windows.
Games are displayed in the playerinfo dialog showing all existing games of the current
player, and in a window opened via menu "Games - List games" which shows all games in
the index. In this window you can search for a player using the "Search player" textbox.
If you enable the option "Add players when scanning SGFs" in the Settings menu, player
names are automatically added to the players list as neutral entries when SGF files
are scanned and included into the games index or when glGo autosaves a game. You can
use the "Cleanup" menuitem to get rid of those entries again if you need to.

Some statistics gathered from the scanned games are displayed as history in the
playerinfo dialog. This feature looks through the SGF game index and collects data
of games you played with the given user to display the wins and losses. Obviously,
you need to collect some SGF games from glGo/gGo to get some meaningful data. Use the
autosave feature and re-index your SGF files now and then.
The Playermanager needs to know who you are, as it looks for games between "myname"
and "opponent". You can enter your username in the Settings menu. If nothing is set,
it will take the last IGS loginname from the glGo config file. This history data is
also displayed in the glGo match and playerinfo dialogs. glGo will reload the index
file on demand if the file mtime changed, so you can use the Playermanager and change
the index while running glGo.

If you build a serious player database, it might be a good idea to make a backup now
and then. The file is $HOME/.glGo/players.db (Linux) and $HOME\glGo\players.db
(Windows). Not much can go wrong with the SGF file scanning, as the SGF files are
only opened in read-mode, never in write-mode. Make your SGFs read-only if you are
suspicious.


Using with gGo
--------------

To use the playermanager database in gGo, open the gGo preferences dialog and enable
"Use glGo Playermanager" in the "Advanced" tab. Now gGo will use the same database
as glGo instead of its own built-in list. When this feature is enabled, you will get
a new tab in the playerinfo dialog, quite similar to the glGo dialog.

You can import your gGo friends list (the one in the old format which is used if
the above option is disabled) either using the ggo2pm script or the from the
Playermanager GUI, see menu File - Import list from gGo.


Copyright
---------

Copyright (c) 2003-2005 PANDANET Inc.

Written by Peter Strempel <pstrempel@panda-igs.joyjoy.net>.

This software is provided 'as-is', without any express or implied warranty,
without even the implied warranty of merchantability or fitness for a particular
purpose. In no event will the authors be held liable for any damages arising
from the use of this software.


Acknowledgements
----------------

The Windows Python standalone is created using py2exe, see http://py2exe.sourceforge.net
The Playermanager GUI is based on wxPython, see http://www.wxpython.org
The player database ideas and concepts are based on the Ambassador IGS client.
