next up previous contents
Next: About this document ... Up: Stats manual for Stats Previous: Command line options   Contents

Subsections


Configuration and command files

Stats uses two different types of file. Those that contain information on the layout of the file system and the host settings: the master configuration file. And command files for the individual players: the player command files.

Inner workings

Every line in the files can contain one or no start commands. A backslash can be used to mask end of lines to keep the file more readable. Commentary can be inserted in two ways. Firstly everything after a # is ignored until the end of the line. Secondly everything between '/*' and '*/' is ignored, including new lines. Whitespace can be used in any amount desired, except within keywords. After multiple character commands it is used as a separator. In that case at least one white space character is required.

None of the above will be much of a surprise. The sections below describe the commands and options supported by both the master configuration and the player command file.

filename
The name of a file. '$\sim$', '_' and '/' accepted as well as all alpha numerical characters.
planetname
The name of the planet as it appears in planets. You only need to use enough charaters to uniquely identify the planet. Ambiguity is reported, also when using alternative planet lists. The following characters are accepted: [:alnum:], space, quote, and hyphen.
exp
numerical expression including one of the following operators. Mathematical ordering is applied to the expression evaluation. This means that multiplication takes place before adding up etc. For americans under the readers multiplication has presedence above devission.

exp + exp add
exp - exp subtract
- exp multiply by -1
exp / exp divide
exp * exp multiply
( exp ) evaluate exp between braces first.
exp $\wedge$ exp raise first exp to the power of second exp
_ exp root

toggle
Can be either of the following yes, no, true, false, 1, 0. Matching is case-insensitive.
float
Decimals are separated by a dot.


Master configuration file

The master configuration file is parsed directly after the evaluation of the command line options. This implies that settings in the master command file overrule the command line options given.

The master configuration file contains the following start commands:

BaseDir <filename>
PlayerDir <filename>
Miningrate <float,float,float,float,float,float,
  float,float,float,float,float>
CrystalsLikeDesert <toggle>
ClimateLimitsPopulation <toggle>
CrystalSinTempBehavior <toggle>
MaxColTempSlope <float>
NeutronicDecay <float>
UseAccurateFuelModel <toggle>
AllowEatingSupplies <toggle>
AllowAdvancedRefinery <toggle>
AllowAlchemy <toggle>
RaceGrowthRate <float,float,float,float,float,float,
  float,float,float,float,float>
GravityWellRange <float>
NativeDeathRate <float>
ClimateDeathRate <float>
BorgAssimilationRate <float>
OutputFile <filename>
Unpack  

BaseDir
Location of the planets directory.
PlayerDir
Location of the rst and player data files.
Miningrate
See phost documentation for its effect.
CrystalsLikeDesert
See phost documentation for its effect.
ClimateLimitsPopulation
See phost documentation for its effect.
CrystalSinTempBehavior
See phost documentation for its effect.
MaxColTempSlope
See phost documentation for its effect.
NeutronicDecay
See phost documentation for its effect.
UseAccurateFuelModel
See phost documentation for its effect.
AllowEatingSupplies
See phost documentation for its effect.
AllowAdvancedRefinery
See phost documentation for its effect.
AllowAlchemy
See phost documentation for its effect.
RaceGrowthRate
See phost documentation for its effect.
gravityWellRange
See phost documentation for its effect. Square wells are assumed.
NativeDeathRate
See phost documentation for its effect.
climateDeathRate
See phost documentation for its effect.
BorgAssimilationRate
See phost documentation for its effect.
OutputFile
Redirects the non-error output to the file given.
Unpack
Unpacks the rst files in the playerDir when present. Same as command line option -u.


Player command file

The player configuration file is parsed after the processing of the command line options for that player. Commands found in the command file fall into 3 execution categories.

Some are executed immidiatly after they are parsed. This applies unless stated otherwise below to all reports, and parameter settings. For example colhappytarget, outputfile, report fleet.

All other commands are executed after parsing the entire command file. They are then prioritized, and executed in the priority order. Commands of the same priority are executed in the order given in the command file. For further details see 1.1.

Something to take into consideration when playing multiple races.

Start commands

planet <exp $\Vert$ planetname>: <planet actions>
base <exp $\Vert$ planetname>: <turn> <base actions>
resourcemutation <planetname>: <turn> <resource actions>
report <report type>  
tax    
setfc    
mdatatotxt    
colhappytarget <exp>  
nathappytarget <exp>  
colhappythreshold <exp>  
nathappythreshold <exp>  
wantplanetemptyinturns <exp>  
outputfile <filename>  
autofixatbases <togle>  
autounloadatbases <togle>  
warnonbuildfailure <togle>  
autoloadmerlins <togle>  

planet
links actions to planets. The actions are executed in the order given (top to bottom, left to right). Multiple planet commands can be given for the same planet. The ordering of planets is irrelevant for the processing.
base
actions to perform on base in future turn, see section 4.3.3 for further details.
report
Request a report to be displayed. For possibilities see section 4.3.5.
tax
Same as -ct. Set tax for all planets. This command is executed immediatly.
setfc
Randomise non-special planetary friendly codes. Same as -cf. This command is executed immediatly.
mdatatotxt
convert mdata.dat to a human readable mdata.txt file. Same as the 't' in -ut. This command is executed immediatly.
colhappytarget
Set colonist happiness targets for taxation. Same as -T<Colonists>.
nathappytarget
Set native happiness targets for taxation. Same as the [Natives] from -T<Colonists[,Natives]>.
colhappythreshold
Same as colhappytarget.
nathappythreshold
Same as nathappytarget.
wantplanetemptyinturns
Modifier for the default behaviour of the -dM option. It sets the target number of turns to turn the planet ground stores into surface stores.
outputfile
Redirects the non-error output to the file given.
autofixatbases
For all starbases; The most damaged ship, if any, is ordered to be fixed at the starbase. Default is off.
autounloadatbases
For all starbases; minerals, supplies, and megacredits are unloaded from all ships. Default is off.
warnonbuildfailure
When a ship command fails insert addional (empty) resource mutation warning of the failure. Default is off.
autoloadmerlins
Load as many supplies as possible into all merlins removing any other cargo as needed. Default is off.


Planet actions

The following planet commands are supported. These commands are case sensitive. Each letter is interpreted as a qualified command.

f <exp>  
m <exp>  
d <exp>  
b <exp>  
p <exp>  
F <exp>  
t <exp>  

f
build factories up unto the number specified.
m
build mines up unto the number specified.
d
build planetary defense posts up unto the number specified.
b
build a starbase.
p
build defense posts on the base up unto the number specified.
F
build fighters in the base up unto the number specified.
t
tax this planet. This only makes sence when no general tax command is in place.


Base actions

The base commands listed below are supported. They may appear in any order, and in any frequency. Actions listed first in the command file have presedence over actions listed later in case of resource contention.

engines <exp> <engine type>    
beams <exp> <beam type>    
tubes <exp> <torp type>    
hulls <exp> < hull type>    
ship < hull type> <engine type> [[<beam type>] <torp type>]
torpedoes <exp> < torp type>    
techlevel <tech type> <exp>    
fighters <exp>      
mission <base mission>      
defense <exp>      

engines
build exp number of engines of type engine type .
engine type
This is either the slot number, or a keyword string. The following keywords, or unique start part thereof, are supported for engine type: stardrive1, stardrive2, stardrive3, superstardrive4, novadrive5, heavynovadrive6, quantamdrive7, hypderdrive8, transwarpdrive, w1, w2, w3, w4, w5, w6, w7, w8, w9, warp1, warp2, warp3, warp4, warp5, warp6, warp7, warp8, warp9.
beams
build exp number of beams of type beam type .
beam type
This is either the slot number, or a keyword string. The following keywords, or unique start part thereof, are supported for beam type: "laser", "xraylaser", "plasmabolt", "blaster", "positronbeam", "disruptor", "heavyblaster", "hblaster", "phaser", "heavydisruptor", "hdisruptor", "heavyphaser", "hphaser", "beam1", "beam2", "beam3", "beam4", "beam5", "beam6", "beam7", "beam8", "beam9", "beam10".
tubes
build exp number of torpedoe tubes of type torp type .
torp type
This is either the slot number, or a keyword string. The following keywords, or unique start part thereof, are supported for torp type: The following keywords are supported for torp type: "mark1", "mk1", "protontorpedo", "mark2", "mk2", "gammabomb", "mark3", "mark4", "mark5", "mark6", "mark7", "mark8", "mk3", "mk4", "mk5", "mk6", "mk7", "mk8".
hulls
build exp number of hulls of type hull type .

hull type
This is either the slot number from the hullspec.dat file, or a keyword string. The keywords, or unique first part thereof, are formed as follows. Short ship types as described in 3.1 under the rt option, or the long ship type. Of the later the white space and special characters are removed. So T-REX CLASS BATTLESHIP becomes trexclassbattleship. Case is irrelevant in the matching.

ship
set a build order for the specified ship at the starbase. Parts are build as needed. Techlevels are raised as needed. In case needed parts are already present these are used. When resources do not permit to build the ship the order is not set at the base, but parts that can be build are build.
torpedoes
build exp number of torpedoes of type torp type .
tech
Raise tech tech type to level exp .
tech type
The following keywords are supported for tech type:
fighters
Same as planet F options. Builds up to exp fighters
mission
Set base mission to base mission .
base mission
The following keywords are supported for base mission:
defense
Same as planet p options. Builds up to exp starbase defense posts.


Resource actions

The resource actions listed below are supported. The intention is to allow you to specify miracles regarding resources. Like an ally dropping off some goods on your planet.

n <exp>  
t <exp>  
d <exp>  
m <exp>  
s <exp>  
$ <exp>  
c <exp>  

exp can evaluate to a negative number. In that case resource are removed from the planet. When insufficient resources are available for removal those available are removed.

All the commands in this subsection are only applied to future turns. Not the current turn. This to avoid file trn file corruption.

n
Create neutroneum.
t
Create tritanium.
d
Create duranium.
m
Create molydenium.
s
Create supplies.
$
Create credits.
c
Create colonists.


Report types

summary    
fleet Fleet report options  
hull Hull report options  
base Base report options  
targets Target report options  
economy Planet report options  
buildqueue planetname  
levy    
nopcommands    

summary
Same as -s.
fleet
Same as the command line option -x.
fleet report options
are letter codes. They are the same as for the command line option.
hull
Same as the command line option -r.
hull report options
are letter codes. They are the same as for the command line option.
base
Same as the command line option -b.
base report options
are letter codes. They are the same as for the command line option.
targets
Same as the command line option -t.
target report options
are letter codes. They are the same as for the command line option.
economy
Same as the command line option -d.
economy report options
are letter codes. They are the same as for the command line option.
buildqueue
Displays the buildqueue for the given planet. This is a universal command.
levy
Same as the command line option -l.
nopcommands
Reports the planets owned by the player which do not have commands in the command list. This is a universal command.


next up previous contents
Next: About this document ... Up: Stats manual for Stats Previous: Command line options   Contents
Reinout van Rees 2003-06-23