koth: C replacement for koth.bat -------------------------------- Version 0.02: 16 June 2001 Copyright (c) 1998, 2001 Philip Kendall ------------------------------------------------------------------------------ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. ------------------------------------------------------------------------------ 0. Contents ----------- 1. Overview 2. koth 3. .kothrc 4. Author contact information 1. Overview ----------- This program is basically a straight C replacement of koth.bat, the batch file supplied with the Wilkies suite of warriors which allows the strength of a given warrior against a fixed set of warriors to be estimated. The original Wilkies suite is available from: http://www.koth.org/wilkies/wilkies.html 2. koth ------- The actual program is fairly simple to invoke: koth [warriorfile] [rounds] [suite] warriorfile is the warrior file which you wish to test (including any .red extension) rounds is the number of rounds over which you wish each battle to be fought suite is the name of a suite of warriors, as defined in the configuration file (see below) koth will read parameters such as the simulator to use from its configuration file, which should be in the directory from which it is invoked. The name of the configuration file is `.kothrc' (`kothrc' for DOS systems). Definitions of the suites of warriors should also be placed in the config file. The aim of this program was to produce results which were identical to the original (there is a slight difference on the second line of output). Note however that this program writes the results to standard output, as opposed to the .log of the original. 3. .kothrc ---------- The configuration file (`.kothrc' or `kothrc' on DOS systems) has the following format: 1st line: The name of the simulator to run, along with any arguments which you wish to be passed every time you run the simulator (for example `pmars -b'). 2nd and subsequent lines: Definitions of the suites of warriors which can be selected. Each suite must be specified on one line and the fields separated by commas. Each suite definition has the following form: suitename,options,warrior1[,warrior2[,warrior3[...]]] suitename is the name of the suite (as selected with the third command-line parameter). options is any options specific to this suite warrior[n] is the path to a warrior to be fought. Some examples of suite definitions include: [The classic Wilkies suite] wilkies,,time.red,nobody.red,paperone.red,marcia13.red,bluefunk.red, cannon.red,tornado.red,fstorm.red,rave.red,irongate.red,pswing.red, thermite.red [Some low process warriors -- note the -@ lp.opt option] lp,-@ lp.opt,golden.red,infern18.red,lowprice.red,paperlp2.red,sandston.red, simplici.red,tetraqua.red,triad.red,tribbles.red,tricks.red,twinflam.red, warbird.red Both these definitions must actually be one line only, but are wrapped here to make reading easier. 4. Author contact information ----------------------------- E-mail: Philip Kendall Homepage: http://www.srcf.ucam.org/~pak21/corewar/index.html Postal address: 15 Crescent Road, Wokingham, Berks, RG40 2DB, England