chiark / gitweb /
1d2755ae7acbc597a4a5bc8653fafb115c5f2664
[rocl] / README
1 RIGHT ON COMMAND-LINE
2   Elite tools for the discerning player
3
4 1. Installation
5
6         You need a C compiler and a working Tcl/Tk installation.  (The
7         elite-editor program needs Tk; the rest of the tools don't.)
8         The Makefile works on my Debian GNU/Linux box, but I'm not
9         making any promises about anyone else's.  I've successfully
10         built earlier versions of everything under Cygwin, against
11         ActiveState's Tcl 8.4, but I've forgotten the Holy Runes.  I do
12         have the `.def' file I used to build the DLL, though, for
13         whatever that's worth.  (If you want to hack the Makefile to
14         work under Windows, I'll take a patch.)
15
16         The theory is that you should edit the Makefile for your system
17         and say `make'; then, as some suitably privileged person, say
18         `make install' and stand well back.  Everything should then be
19         installed.
20
21         In practice:
22
23           * If you can't build `pkgIndex.tcl', run `tclsh' and say
24
25               % pkg_mkIndex -verbose -direct . elite.so elite.tcl
26
27             to it.  (Use `elite.dll' if you're on Windows.)  Say
28
29               % set tcl_pkgPath
30
31             to see a list of suitable places for putting the kit.  Pick
32             one.  The directory `/usr/local/lib' appears in my
33             installation, so that's what I use.
34
35           * Make a subdirectory in the place you chose, and copy
36             `elite.so', `elite.tcl' and `pkgIndex.tcl' into it.  All
37             should now be hunky-dory.
38
39           * Run (say) `elite-describe lave' to check that things are set
40             up properly.
41
42
43 2. The command-line tools
44
45         A `galaxy-spec' is
46
47           * a number, between 1 and 8, for one of the standard eight
48             galaxies; 
49
50           * a `galaxy seed' of 12 hex digits (a 48-bit value), for any
51             arbitrary galaxy; or
52
53           * a string `SEED:N' where SEED is a galaxy seed and N is a
54             number between 1 and 8, for the Nth galaxy in some custom
55             universe.
56
57         A `planet-spec' is interpreted relative to some parent galaxy.
58         It may be
59
60           * a number N, for the Nth planet in the galaxy (planets are
61             numbered pseudorandomly -- this is not often a helpful
62             option);
63
64           * a `planet seed' of 12 hex digits (a 48-bit value), for any
65             arbitrary planet;
66
67           * a pair of numbers `X,Y', for the planet nearest the point X
68             decilightyears rightwards and T decilightyears down from the
69             top left of the galaxy;
70
71           * a glob pattern (a string containing `*' and `?' wildcards,
72             matching any substring or any single character,
73             respectively), for the first planet whose name matches the
74             pattern; or
75
76           * a string `GAL:P', where GAL is a galaxy-spec and P is a
77             planet-spec, for the planet P in galaxy GAL.
78
79
80   elite-describe [-g GAL] PLANET ...
81
82         For each PLANET, print the planet data for that PLANET.  The
83         PLANETs are interpreted relative to GAL, or standard galaxy 1 if
84         GAL is not specified.
85
86
87   elite-map [-qv] [-g GALAXY] [-d DIST] [-w WD,HT] [-a ASP] [PLANET]
88
89         Prints a map of (part of) a galaxy to the terminal.
90
91         If PLANET is specified (which it usually is), a map of the area
92         around PLANET in GALAXY (default standard galaxy 1) is printed,
93         showing other planets within DIST lightyears (default 7) of
94         PLANET.
95
96         If PLANET is not specified, the entire galaxy is printed.  This
97         is usually unhelpful.
98
99         Planets are shown as numbers or letters.  The home PLANET is
100         shown as a `*'.  Below the map is printed a key describing the
101         planets in a strict left-to-right top-to-bottom order.
102
103         The size of the map may be controlled by the -w option -- set WD
104         to the maximum allowable width, and HT to the maximum allowable
105         height (in columns and rows, respectively).  The map will be
106         scaled so as to fit.  The -a option sets the aspect ratio of
107         your characters, height to width (the default is about 2, and
108         seems right for viewing in an xterm with the standard fixed
109         font).
110
111
112   elite-path [-g GALAXY] [-w WEIGHT] PLANET PLANET ...
113
114         Computes a route through a GALAXY (default is standard galaxy
115         1), starting at the first PLANET listed, via the second, via the
116         third, etc., and ending at the last.  For each planet you're
117         meant to stop at on the way, a summary line is printed giving
118         the planet's name, position, government type, economy type and
119         tech level.
120
121         You can affect how elite-path selects its routes using the `-w'
122         option.  The default is to minimize the number of hops.  Other
123         possibilities are:
124
125         hops            Minimize number of hops.  This is the default.
126
127         safety          Maximize stability of the planets in the route,
128                         to attempt to improve safety.  Useful during the
129                         early stages of the game.
130
131         encounters      The opposite of `safety' -- minimizes stability
132                         of planets in the route.  Useful if you want to
133                         maximize kills.
134
135         trading         Maximize the difference in economy type between
136                         successive planets in the route.  This should
137                         give you an opportunity to make a good profit as
138                         you go.
139
140         fuel            Minimize absolute distance.  For those on a
141                         tight budget.
142
143
144   elite-reach [-d DIST] [GALAXY ...]
145
146         For each GALAXY (default is the 8 standard ones), print summary
147         information for each planet, with blank lines separating
148         disconnected groups of planets, i.e., groups where a ship
149         capable of travelling DIST lightyears (default 7) can't get from
150         one to the other.
151
152
153   elite-find [-g GALAXY] [EXPR]
154
155         Without EXPR, simply prints summary information for each planet
156         in GALAXY (default standard 1).
157
158         If EXPR is specified, it must be a Tcl expression (as for the
159         `expr' command).  Information is printed for each planet for
160         which EXPR returns nonzero.  The EXPR may use the following
161         variables:
162
163         name            The planet name, with initial capital letter.
164
165         x, y            X and Y coordinates, from top left, in
166                         decilightyears.
167
168         economy         From 0 (rich industrial) to 7 (poor
169                         agricultural).
170
171         government      From 0 (anarchy) to 7 (corporate state).
172
173         techlevel       From 1 to 15.
174
175         radius          In kilometres.
176
177         productivity    In millions of credits.
178
179         population      In hundreds of millions.
180
181         inhabitants     A Tcl list of words describing the inhabitants.
182
183         description     As a Tcl list of words.
184
185
186   elite-pairs [-g GALAXY] [-d DIST] AEXPR BEXPR
187
188         Prints the names of pairs of planets A and B in GALAXY (default
189         standard 1), no further than DIST (default 7) lightyears apart,
190         such that AEXPR returns nonzero for planet A and BEXPR returns
191         nonzero for planet B.
192
193         The expressions AEXPR and BEXPR may use the same variables as
194         for elite-find.  In addition, BEXPR may use
195
196         d               The distance between planets A and B.
197
198         a               An array containing the information about planet
199                         A.  The indices have the same names and meanings
200                         as the variables described above.
201
202
203 3. The graphical editor
204
205   elite-editor [GALAXY | FILE]
206
207         Starts the RIGHT ON COMMAND-LINE Commander Editor and Map.  This
208         is a Tk program -- you'll need that installed to run it.
209
210         I'll not go into excruciating detail about how to work the
211         program.  It's fairly simple, really.
212
213         The map view lets you colour-code planets according to
214         techlevel, government or economy.  The colours ought to be as
215         follows:
216
217         Colour          Government      Economy         Techlevel
218
219         Red             Anarchy         Poor agri       1
220         Orange          Feudal          Average agri    2 or 3
221         Yellow          Multi-gov       Rich agri       4 or 5
222         Green           Dictatorship    Mainly agri     6 or 7
223         Blue            Communist       Mainly indust   8 or 9
224         Magenta         Confederacy     Poor indust     10 or 11
225         Violet          Democracy       Average indust  12 or 13
226         White           Corporate       Rich indust     14 or 15
227
228         The connectivity map shows how you can get around the galaxy
229         using hops of up to 7 light years.
230
231         Planet names are unhelpful except at small scales.  The
232         placement algorithm could do with a lot of work.
233
234         Clicking on the map with button 1 (usually the left one) sets
235         the destination world, marked with an orange cross.  Clicking
236         with button 3 (usually the right one) sets the home world,
237         marked with a red cross, and with a green hyperspace-range
238         circle around it.  (The circle doesn't actually correspond
239         exactly with hyperspace reachability, because there are rounding
240         errors in the distance computation.  ROCL correctly emulates the
241         rounding errors from the original game.)
242
243         Double-clicking opens a window showing information about a
244         planet.  Two info windows can be open at any time, one for the
245         home world and one for the destination.
246
247         The bar along the bottom of the map window shows the names of
248         the home and destination worlds, and the distance between them.
249         You can type new names (or any old planet spec) into either to
250         select different planets.  The change will take place when you
251         press return or when the input focus moves.
252
253         The `Compute path' lets you do the same kinds of computations as
254         the elite-path tool.  It plots a route from the home to the
255         destination.  The path is shown in orange on the map.
256
257         The commander editor should be self-explanatory, but maybe a few
258         pointers might be helpful.
259
260         The entry fields for items with pop-up menus are disabled when
261         the menus show values other than `Custom', so you must first
262         choose `Custom' from the menu if you want a fancy value.
263
264         The `Show galaxy map' button opens a map which will be tied to
265         the commander window.  When you select a home world (button 3),
266         this will set the world where the commander will start.  Note
267         that the market prices (in the `Cargo' window) update
268         automatically as you move about the universe.  It is quite
269         possible to travel about entirely new universes by turning off
270         the `Standard galaxy' button and typing some hex number into the
271         `Galaxy seed' box.  All of the ROCL tools work in these custom
272         universes.  Note that your docked planet is recorded as an x, y
273         coordinate pair, so Elite can't tell which of two coincident
274         planets you're docked at (yes, there are such pairs).  ROCL
275         won't cope with this at the moment.
276
277         Lasers are a bit odd.  Bit 7 is a `rapid-fire' bit.  It doesn't
278         affect the strength of the laser, but means that there's no
279         delay between shots.  The low 7 bits control the strength, but
280         without the rapid-fire bit, powerful lasers will tend to fire
281         more slowly than weak ones.  Some comparisons in the program are
282         for exact laser power: you can't damage the Constrictor or
283         Cougar ships unless you have military (or 0x17 slow-firing)
284         lasers; and you can't fragment asteroids unless you have mining
285         or 0xb2 rapid-fire lasers.  (The 0xb2's pack a serious punch.  I
286         recommend them as an upgrade for commanders who don't wish to
287         cheat completely.)
288
289 $Id: README,v 1.2 2003/02/25 00:25:38 mdw Exp $
290 \f
291 Local variables:
292 mode: text
293 End: